From c5615060b407031a4a0367404f8fa78976f2f2db Mon Sep 17 00:00:00 2001 From: Andrew Dryga Date: Fri, 31 Mar 2023 09:51:40 -0600 Subject: [PATCH] Remove fz_vpn, fz_wall, Omnibus and start restructuring apps --- .codespellrc | 2 +- .dockerignore | 6 +- .github/workflows/omnibus_build.yml | 166 - .github/workflows/omnibus_publish.yml | 183 - .github/workflows/static_analysis.yml | 16 +- .github/workflows/test.yml | 17 +- .gitignore | 8 +- .pre-commit-config.yaml | 8 - .rubocop.yml | 6 - .tool-versions | 1 - Dockerfile.dev | 16 +- Dockerfile.prod | 10 +- Gemfile | 5 - Gemfile.lock | 35 - apps/{fz_http/lib => domain}/fz_http.ex | 0 .../lib => domain}/fz_http/api_tokens.ex | 0 .../fz_http/api_tokens/api_token.ex | 0 .../fz_http/api_tokens/api_token/changeset.ex | 0 .../fz_http/api_tokens/api_token/query.ex | 0 .../fz_http/api_tokens/authorizer.ex | 0 .../lib => domain}/fz_http/application.ex | 0 apps/{fz_http/lib => domain}/fz_http/auth.ex | 0 .../lib => domain}/fz_http/auth/authorizer.ex | 0 .../lib => domain}/fz_http/auth/context.ex | 0 .../lib => domain}/fz_http/auth/mfa.ex | 0 .../lib => domain}/fz_http/auth/mfa/method.ex | 0 .../fz_http/auth/mfa/method/changeset.ex | 0 .../fz_http/auth/mfa/method/query.ex | 0 .../lib => domain}/fz_http/auth/oidc.ex | 0 .../fz_http/auth/oidc/connection.ex | 0 .../fz_http/auth/oidc/connection/changeset.ex | 0 .../fz_http/auth/oidc/connection/query.ex | 0 .../fz_http/auth/oidc/refresh_manager.ex | 0 .../fz_http/auth/oidc/refresher.ex | 0 .../lib => domain}/fz_http/auth/permission.ex | 0 .../lib => domain}/fz_http/auth/role.ex | 0 .../lib => domain}/fz_http/auth/roles.ex | 0 .../fz_http/auth/saml/start_proxy.ex | 0 .../lib => domain}/fz_http/auth/subject.ex | 0 .../{fz_http/lib => domain}/fz_http/config.ex | 0 .../fz_http/config/authorizer.ex | 0 .../lib => domain}/fz_http/config/caster.ex | 0 .../fz_http/config/configuration.ex | 0 .../fz_http/config/configuration/changeset.ex | 0 .../configuration/openid_connect_provider.ex | 0 .../configuration/saml_identity_provider.ex | 0 .../fz_http/config/definition.ex | 0 .../fz_http/config/definitions.ex | 0 .../lib => domain}/fz_http/config/dumper.ex | 0 .../lib => domain}/fz_http/config/errors.ex | 0 .../lib => domain}/fz_http/config/fetcher.ex | 0 .../lib => domain}/fz_http/config/logo.ex | 0 .../lib => domain}/fz_http/config/resolver.ex | 0 .../fz_http/config/validator.ex | 0 .../fz_http/connectivity_checks.ex | 0 .../fz_http/connectivity_checks/authorizer.ex | 0 .../connectivity_checks/connectivity_check.ex | 0 .../connectivity_check/changeset.ex | 0 .../connectivity_check/query.ex | 0 .../fz_http/connectivity_checks/poller.ex | 0 .../{fz_http/lib => domain}/fz_http/crypto.ex | 0 .../lib => domain}/fz_http/devices.ex | 0 .../fz_http/devices/authorizer.ex | 0 .../lib => domain}/fz_http/devices/device.ex | 0 .../fz_http/devices/device/changeset.ex | 0 .../fz_http/devices/device/query.ex | 0 .../fz_http/devices/stats_updater.ex | 0 .../fz_http/encrypted/binary.ex | 0 .../lib => domain}/fz_http/encrypted/map.ex | 0 .../lib => domain}/fz_http/name_generator.ex | 0 .../lib => domain}/fz_http/release.ex | 0 apps/{fz_http/lib => domain}/fz_http/repo.ex | 0 .../lib => domain}/fz_http/repo/notifier.ex | 0 apps/{fz_http/lib => domain}/fz_http/rules.ex | 0 .../fz_http/rules/authorizer.ex | 0 .../lib => domain}/fz_http/rules/rule.ex | 0 .../fz_http/rules/rule/changeset.ex | 0 .../fz_http/rules/rule/query.ex | 0 .../{fz_http/lib => domain}/fz_http/server.ex | 0 .../lib => domain}/fz_http/telemetry.ex | 0 .../fz_http/telemetry/posthog.ex | 0 .../lib => domain}/fz_http/telemetry/timer.ex | 0 .../lib => domain}/fz_http/types/cidr.ex | 0 .../lib => domain}/fz_http/types/inet.ex | 0 .../lib => domain}/fz_http/types/int4range.ex | 0 .../lib => domain}/fz_http/types/ip.ex | 0 .../lib => domain}/fz_http/types/ip_port.ex | 0 .../lib => domain}/fz_http/types/protocols.ex | 0 apps/{fz_http/lib => domain}/fz_http/users.ex | 0 .../fz_http/users/authorizer.ex | 0 .../lib => domain}/fz_http/users/user.ex | 0 .../fz_http/users/user/changeset.ex | 0 .../fz_http/users/user/query.ex | 0 .../lib => domain}/fz_http/validator.ex | 0 apps/{fz_http/lib => domain}/fz_http/vault.ex | 0 .../fz_http/vpn_session_scheduler.ex | 0 apps/fz_http/lib/fz_http/events.ex | 93 - apps/fz_http/lib/fz_http/notifications.ex | 101 - apps/fz_vpn/.formatter.exs | 9 - apps/fz_vpn/.gitignore | 23 - apps/fz_vpn/README.md | 3 - apps/fz_vpn/coveralls.json | 6 - apps/fz_vpn/lib/fz_vpn.ex | 5 - apps/fz_vpn/lib/fz_vpn/application.ex | 12 - apps/fz_vpn/lib/fz_vpn/interface.ex | 205 - .../fz_vpn/lib/fz_vpn/interface/wg_adapter.ex | 17 - .../lib/fz_vpn/interface/wg_adapter/live.ex | 11 - .../fz_vpn/interface/wg_adapter/sandbox.ex | 101 - apps/fz_vpn/lib/fz_vpn/keypair.ex | 33 - apps/fz_vpn/lib/fz_vpn/server.ex | 91 - apps/fz_vpn/lib/fz_vpn/stats_push_service.ex | 31 - apps/fz_vpn/mix.exs | 46 - apps/fz_vpn/test/fixtures/.gitkeep | 0 apps/fz_vpn/test/fz_vpn/interface_test.exs | 85 - apps/fz_vpn/test/fz_vpn/server_test.exs | 55 - .../test/fz_vpn/stats_push_service_test.exs | 3 - apps/fz_vpn/test/fz_vpn_test.exs | 4 - apps/fz_vpn/test/test_helper.exs | 1 - apps/fz_wall/.formatter.exs | 9 - apps/fz_wall/.gitignore | 23 - apps/fz_wall/README.md | 3 - apps/fz_wall/lib/fz_wall.ex | 18 - apps/fz_wall/lib/fz_wall/application.ex | 18 - apps/fz_wall/lib/fz_wall/cli.ex | 9 - apps/fz_wall/lib/fz_wall/cli/helpers/nft.ex | 290 - apps/fz_wall/lib/fz_wall/cli/helpers/sets.ex | 69 - apps/fz_wall/lib/fz_wall/cli/live.ex | 167 - apps/fz_wall/lib/fz_wall/cli/sandbox.ex | 16 - apps/fz_wall/lib/fz_wall/server.ex | 110 - apps/fz_wall/lib/fz_wall/shell.ex | 38 - apps/fz_wall/mix.exs | 46 - apps/fz_wall/test/cli/helpers/nft_test.exs | 18 - apps/fz_wall/test/cli/live_test.exs | 23 - apps/fz_wall/test/fz_wall_test.exs | 4 - apps/fz_wall/test/test_helper.exs | 1 - apps/{fz_http => web}/.formatter.exs | 0 apps/{fz_http => web}/.gitignore | 0 apps/{fz_http => web}/README.md | 0 apps/{fz_http => web}/assets/.babelrc | 0 apps/{fz_http => web}/assets/config.dev.js | 0 apps/{fz_http => web}/assets/config.prod.js | 0 apps/{fz_http => web}/assets/css/app.scss | 0 apps/{fz_http => web}/assets/css/email.scss | 0 apps/{fz_http => web}/assets/css/main.scss | 0 apps/{fz_http => web}/assets/css/tables.scss | 0 apps/{fz_http => web}/assets/esbuild.js | 0 apps/{fz_http => web}/assets/js/admin.js | 0 apps/{fz_http => web}/assets/js/crypto.js | 0 .../assets/js/event_listeners.js | 0 apps/{fz_http => web}/assets/js/hooks.js | 0 apps/{fz_http => web}/assets/js/live_view.js | 0 apps/{fz_http => web}/assets/js/qrcode.js | 0 apps/{fz_http => web}/assets/js/root.js | 0 .../assets/js/unprivileged.js | 0 apps/{fz_http => web}/assets/js/util.js | 0 apps/{fz_http => web}/assets/js/wg_conf.js | 0 .../admin-one-bulma-dashboard/.editorconfig | 0 .../admin-one-bulma-dashboard/.gitattributes | 0 .../admin-one-bulma-dashboard/.gitignore | 0 .../admin-one-bulma-dashboard/.tool-versions | 0 .../admin-one-bulma-dashboard/LICENSE | 0 .../admin-one-bulma-dashboard/README.md | 0 .../admin-one-bulma-dashboard/package.json | 0 .../admin-one-bulma-dashboard/src/js/main.js | 0 .../src/scss/_aside.scss | 0 .../src/scss/_card.scss | 0 .../src/scss/_footer.scss | 0 .../src/scss/_form.scss | 0 .../src/scss/_hero-bar.scss | 0 .../src/scss/_main-section.scss | 0 .../src/scss/_misc.scss | 0 .../src/scss/_mixins.scss | 0 .../src/scss/_modal.scss | 0 .../src/scss/_nav-bar.scss | 0 .../src/scss/_table.scss | 0 .../src/scss/_theme-firezone.scss | 0 .../src/scss/_tiles.scss | 0 .../src/scss/_title-bar.scss | 0 .../src/scss/libs/_all.scss | 0 .../src/scss/main.scss | 0 apps/{fz_http => web}/assets/package.json | 0 .../{fz_http => web}/assets/postcss.config.js | 0 apps/{fz_http => web}/assets/yarn.lock | 0 apps/{fz_http => web}/coveralls.json | 0 apps/{fz_http => web}/lib/fz_http_web.ex | 0 .../fz_http_web/auth/html/authentication.ex | 0 .../fz_http_web/auth/html/error_handler.ex | 0 .../lib/fz_http_web/auth/html/pipeline.ex | 0 .../fz_http_web/auth/json/authentication.ex | 0 .../fz_http_web/auth/json/error_handler.ex | 0 .../lib/fz_http_web/auth/json/pipeline.ex | 0 .../lib/fz_http_web/authorization_helpers.ex | 0 .../channels/notification_channel.ex | 0 .../lib/fz_http_web/controller_helpers.ex | 0 .../controllers/auth_controller.ex | 0 .../controllers/browser_controller.ex | 0 .../controllers/debug_controller.ex | 0 .../json/configuration_controller.ex | 0 .../controllers/json/device_controller.ex | 0 .../controllers/json/fallback_controller.ex | 0 .../controllers/json/rule_controller.ex | 0 .../controllers/json/user_controller.ex | 0 .../controllers/root_controller.ex | 0 .../controllers/user_controller.ex | 0 .../lib/fz_http_web/doc_helpers.ex | 0 .../lib/fz_http_web/endpoint.ex | 0 .../lib/fz_http_web/error_helpers.ex | 0 .../lib/fz_http_web/gettext.ex | 0 .../lib/fz_http_web/header_helpers.ex | 0 .../connectivity_check_live/index.html.heex | 0 .../connectivity_check_live/index_live.ex | 0 .../live/device_live/admin/index.html.heex | 0 .../live/device_live/admin/index_live.ex | 0 .../live/device_live/admin/show.html.heex | 0 .../live/device_live/admin/show_live.ex | 0 .../live/device_live/new_form_component.ex | 0 .../device_live/new_form_component.html.heex | 0 .../device_live/unprivileged/index.html.heex | 0 .../device_live/unprivileged/index_live.ex | 0 .../device_live/unprivileged/show.html.heex | 0 .../device_live/unprivileged/show_live.ex | 0 .../live/hooks/allow_ecto_sandbox.ex | 0 .../lib/fz_http_web/live/hooks/live_auth.ex | 0 .../lib/fz_http_web/live/hooks/live_mfa.ex | 0 .../lib/fz_http_web/live/hooks/live_nav.ex | 0 .../lib/fz_http_web/live/logo_component.ex | 0 .../fz_http_web/live/mfa_live/auth_live.ex | 0 .../live/mfa_live/register_component.ex | 0 .../live/mfa_live/register_steps_component.ex | 0 .../lib/fz_http_web/live/modal_component.ex | 0 .../live/notifications_live/badge.ex | 0 .../live/notifications_live/badge.html.heex | 0 .../live/notifications_live/index.html.heex | 0 .../live/notifications_live/index_live.ex | 0 .../oidc_live/connections_table_component.ex | 0 .../connections_table_component.html.heex | 0 .../live/rule_live/index.html.heex | 0 .../fz_http_web/live/rule_live/index_live.ex | 0 .../live/rule_live/rule_list_component.ex | 0 .../rule_live/rule_list_component.html.heex | 0 .../live/setting_live/account.html.heex | 0 .../setting_live/account_form_component.ex | 0 .../account_form_component.html.heex | 0 .../live/setting_live/account_live.ex | 0 .../setting_live/client_defaults.html.heex | 0 .../client_defaults_form_component.ex | 0 .../client_defaults_form_component.html.heex | 0 .../live/setting_live/client_defaults_live.ex | 0 .../live/setting_live/customization.html.heex | 0 .../live/setting_live/customization_live.ex | 0 .../setting_live/new_api_token_component.ex | 0 .../live/setting_live/oidc_form_component.ex | 0 .../live/setting_live/saml_form_component.ex | 0 .../live/setting_live/security.html.heex | 0 .../live/setting_live/security_live.ex | 0 .../setting_live/show_api_token_component.ex | 0 .../unprivileged/account.html.heex | 0 .../unprivileged/account_form_component.ex | 0 .../account_form_component.html.heex | 0 .../setting_live/unprivileged/account_live.ex | 0 .../lib/fz_http_web/live/sidebar_component.ex | 0 .../live/user_live/form_component.ex | 0 .../live/user_live/form_component.html.heex | 0 .../live/user_live/index.html.heex | 0 .../fz_http_web/live/user_live/index_live.ex | 0 .../fz_http_web/live/user_live/show.html.heex | 0 .../fz_http_web/live/user_live/show_live.ex | 0 .../user_live/vpn_connection_component.ex | 0 .../live/user_live/vpn_status_component.ex | 0 .../lib/fz_http_web/live_helpers.ex | 0 .../lib/fz_http_web/mailer.ex | 0 .../lib/fz_http_web/mailer/auth_email.ex | 0 .../lib/fz_http_web/mailer/noop_adapter.ex | 0 .../templates/auth_email/magic_link.html.heex | 0 .../templates/auth_email/magic_link.text.eex | 0 .../lib/fz_http_web/oauth/pkce.ex | 0 .../lib/fz_http_web/oidc/state.ex | 0 .../lib/fz_http_web/plug/path_prefix.ex | 0 .../plug/require_local_authentication.ex | 0 .../lib/fz_http_web/plug/samly_target_url.ex | 0 .../lib/fz_http_web/presence.ex | 0 .../lib/fz_http_web/proxy_headers.ex | 0 .../lib/fz_http_web/router.ex | 0 .../lib/fz_http_web/sandbox.ex | 0 .../lib/fz_http_web/session.ex | 0 .../lib/fz_http_web/sockets/user_socket.ex | 0 .../templates/auth/request.html.heex | 0 .../templates/auth/reset_password.html.heex | 0 .../templates/browser/browserconfig.xml.eex | 0 .../templates/layout/admin.html.heex | 0 .../templates/layout/app.html.heex | 0 .../templates/layout/email.html.heex | 0 .../templates/layout/live.html.heex | 0 .../templates/layout/root.html.heex | 0 .../templates/layout/unprivileged.html.heex | 0 .../fz_http_web/templates/root/auth.html.heex | 0 .../templates/shared/device_details.html.heex | 0 .../templates/shared/devices_table.html.heex | 0 .../templates/shared/flash.html.heex | 0 .../templates/shared/head.html.heex | 0 .../templates/shared/heading.html.heex | 0 .../shared/mfa_methods_table.html.heex | 0 .../templates/shared/password_field.html.heex | 0 .../templates/shared/show_device.html.heex | 0 .../shared/socket_token_headers.html.heex | 0 .../templates/shared/submit_button.html.heex | 0 .../templates/shared/user_details.html.heex | 0 .../lib/fz_http_web/user_from_auth.ex | 0 .../lib/fz_http_web/views/auth_view.ex | 0 .../lib/fz_http_web/views/browser_view.ex | 0 .../lib/fz_http_web/views/error_view.ex | 0 .../fz_http_web/views/json/changeset_view.ex | 0 .../views/json/configuration_view.ex | 0 .../lib/fz_http_web/views/json/device_view.ex | 0 .../json/openid_connect_provider_view.ex | 0 .../lib/fz_http_web/views/json/rule_view.ex | 0 .../views/json/saml_identity_provider_view.ex | 0 .../lib/fz_http_web/views/json/user_view.ex | 0 .../lib/fz_http_web/views/layout_view.ex | 0 .../lib/fz_http_web/views/root_view.ex | 0 .../lib/fz_http_web/views/rule_view.ex | 0 .../lib/fz_http_web/views/shared_view.ex | 0 .../lib/fz_http_web/views/user_view.ex | 0 .../views/wireguard_config_view.ex | 0 apps/{fz_http => web}/mix.exs | 0 .../priv/cert/saml_selfsigned.pem | 0 .../priv/cert/saml_selfsigned_key.pem | 0 .../priv/gettext/en/LC_MESSAGES/errors.po | 0 apps/{fz_http => web}/priv/gettext/errors.pot | 0 .../20200225005454_create_users.exs | 0 .../20200228145810_create_devices.exs | 0 .../20200228154815_create_rules.exs | 0 ...10929172417_add_dns_servers_to_devices.exs | 0 ...11116172808_create_connectivity_checks.exs | 0 .../20211116173236_create_settings.exs | 0 ...03012238_change_device_column_defaults.exs | 0 ...1216155557_add_config_token_to_devices.exs | 0 ...211217003247_add_persistent_keepalives.exs | 0 .../20211221183311_add_role_to_users.exs | 0 ...61545_add_require_auth_for_vpn_setting.exs | 0 .../20220103175026_add_inets_to_devices.exs | 0 .../20220111004847_add_mtu_to_devices.exs | 0 .../migrations/20220124162404_add_uuids.exs | 0 ...127021835_rename_persistent_keepalives.exs | 0 ...220127191440_rename_dns_servers_to_dns.exs | 0 .../20220208184257_settings_to_sites.exs | 0 ...9005201_rename_use_default_to_use_site.exs | 0 .../20220211201727_remove_private_keys.exs | 0 .../20220219165023_add_key_regenerated_at.exs | 0 ...5313_add_last_signed_in_method_to_user.exs | 0 .../20220412144151_add_psk_to_devices.exs | 0 .../20220419172036_add_stats_to_devices.exs | 0 ...20427140943_add_description_to_devices.exs | 0 ...20516063916_change_allowed_ips_to_text.exs | 0 ...20220519034545_create_oidc_connections.exs | 0 ...20220520072323_add_disabled_at_to_user.exs | 0 .../20220530073152_create_mfa_methods.exs | 0 ...609232854_change_refresh_token_to_text.exs | 0 .../20220614192937_add_user_id_to_rules.exs | 0 .../20220713050742_create_configurations.exs | 0 .../20220719014442_add_auth_configs.exs | 0 ...5_add_device_rule_user_notify_triggers.exs | 0 .../20220726205646_add_rule_port_range.exs | 0 ..._add_unprivileged_device_configuration.exs | 0 ...ml_identity_providers_to_configuration.exs | 0 ...08_move_auto_create_users_to_providers.exs | 0 ...221129002233_update_on_delete_behavior.exs | 0 .../20221223190406_migrate_pks_to_uuid.exs | 0 ...23357_migrate_datetimes_to_timestamptz.exs | 0 ..._connectivity_checks_inserted_at_index.exs | 0 ...221224210654_fix_sites_nullable_fields.exs | 0 .../20221226044850_create_api_tokens.exs | 0 ...51_move_sites_fields_to_configurations.exs | 0 ...6171558_rename_use_site_to_use_default.exs | 0 .../migrations/20221226193228_drop_sites.exs | 0 ...move_cache_fallbacks_to_configurations.exs | 0 ...221229154115_migrate_providers_configs.exs | 0 ...104000803_add_users_sign_in_token_hash.exs | 0 ...104181853_change_users_email_to_citext.exs | 0 .../20230113184557_add_default_pks_values.exs | 0 ...0116200524_add_not_null_to_mfa_methods.exs | 0 ...ations_default_client_allowed_ips_type.exs | 0 ...143621_change_mfa_methods_unique_index.exs | 0 ...ange_dns_and_allowed_ips_to_inet_array.exs | 0 .../20230223175621_trim_dns_fields.exs | 0 ...1258_remove_devices_key_regenerated_at.exs | 0 apps/{fz_http => web}/priv/repo/seeds.exs | 0 .../static/images/android-chrome-192x192.png | Bin .../static/images/android-chrome-512x512.png | Bin .../priv/static/images/apple-touch-icon.png | Bin .../priv/static/images/favicon-16x16.png | Bin .../priv/static/images/favicon-32x32.png | Bin .../priv/static/images/favicon.ico | Bin .../priv/static/images/logo-text.svg | 0 .../priv/static/images/logo.svg | 0 .../priv/static/images/mstile-150x150.png | Bin apps/{fz_http => web}/priv/static/robots.txt | 0 .../priv/static/site.webmanifest | 0 .../test/fz_http/api_tokens_test.exs | 0 .../test/fz_http/auth/mfa_test.exs | 0 .../test/fz_http/auth/oidc/refresher_test.exs | 0 .../test/fz_http/auth_test.exs | 0 .../test/fz_http/config/caster_test.exs | 0 .../test/fz_http/config/definition_test.exs | 0 .../test/fz_http/config/fetcher_test.exs | 0 .../test/fz_http/config/resolver_test.exs | 0 .../test/fz_http/config/validator_test.exs | 0 .../test/fz_http/config_test.exs | 0 .../connectivity_checks/poller_test.exs | 0 .../test/fz_http/connectivity_checks_test.exs | 0 .../test/fz_http/crypto_test.exs | 0 .../fz_http/devices/device/query_test.exs | 0 .../fz_http/devices/stats_updater_test.exs | 0 .../test/fz_http/devices_test.exs | 0 .../test/fz_http/events_test.exs | 0 .../test/fz_http/name_generator_test.exs | 0 .../test/fz_http/notifications_test.exs | 0 .../test/fz_http/release_test.exs | 0 .../test/fz_http/repo/notifier_test.exs | 0 .../test/fz_http/rules_test.exs | 0 .../test/fz_http/telemetry_test.exs | 0 .../test/fz_http/types/cidr_test.exs | 0 .../test/fz_http/users_test.exs | 0 .../fz_http_web/acceptance/admin_test.exs | 0 .../acceptance/authentication_test.exs | 0 .../acceptance/unprivileged_user_test.exs | 0 .../auth/json/authentication_test.exs | 0 .../channels/notification_channel_test.exs | 0 .../controllers/auth_controller_test.exs | 0 .../controllers/browser_controller_test.exs | 0 .../json/configuration_controller_test.exs | 0 .../json/device_controller_test.exs | 0 .../controllers/json/rule_controller_test.exs | 0 .../controllers/json/user_controller_test.exs | 0 .../controllers/user_controller_test.exs | 0 .../test/fz_http_web/header_helpers_test.exs | 0 .../fz_http_web/html_authentication_test.exs | 0 .../test/fz_http_web/layout_view_test.exs | 0 .../connectivity_check_live/index_test.exs | 0 .../live/device_live/admin/index_test.exs | 0 .../live/device_live/admin/show_test.exs | 0 .../device_live/unprivileged/index_test.exs | 0 .../device_live/unprivileged/show_test.exs | 0 .../fz_http_web/live/mfa_live/auth_test.exs | 0 .../live/notifications_live/badge_test.exs | 0 .../live/notifications_live/index_test.exs | 0 .../fz_http_web/live/rule_live/index_test.exs | 0 .../live/setting_live/account_test.exs | 0 .../setting_live/client_defaults_test.exs | 0 .../live/setting_live/customization_test.exs | 0 .../live/setting_live/security_test.exs | 0 .../unprivileged/account_test.exs | 0 .../fz_http_web/live/user_live/index_test.exs | 0 .../fz_http_web/live/user_live/show_test.exs | 0 .../vpn_connection_component_test.exs | 0 .../user_live/vpn_status_component_test.exs | 0 .../test/fz_http_web/mailer_test.exs | 0 .../sample_email/test_heex.html.heex | 0 .../sample_email/test_multipart.html.eex | 0 .../sample_email/test_multipart.text.eex | 0 .../fz_http_web/plug/path_prefix_test.exs | 0 .../test/fz_http_web/user_from_auth_test.exs | 0 .../fz_http_web/views/error_view_test.exs | 0 .../fz_http_web/views/shared_view_test.exs | 0 .../test/support/acceptance_case.ex | 0 .../test/support/acceptance_case/auth.ex | 0 .../support/acceptance_case/simple_saml.ex | 0 .../test/support/acceptance_case/vault.ex | 0 .../{fz_http => web}/test/support/api_case.ex | 0 .../test/support/case_template.ex | 0 .../test/support/channel_case.ex | 0 .../test/support/conn_case.ex | 0 .../test/support/data_case.ex | 0 .../test/support/docs_generator.ex | 0 .../support/fixtures/api_tokens_fixtures.ex | 0 .../test/support/fixtures/config_fixtures.ex | 0 .../fixtures/connectivity_checks_fixtures.ex | 0 .../test/support/fixtures/devices_fixtures.ex | 0 .../test/support/fixtures/mfa_fixtures.ex | 0 .../fixtures/notifications_fixtures.ex | 0 .../test/support/fixtures/rules_fixtures.ex | 0 .../test/support/fixtures/subject_fixtures.ex | 0 .../test/support/fixtures/users_fixtures.ex | 0 .../test/support/mailer_case.ex | 0 .../test/support/mailer_test_adapter.ex | 0 .../test/support/test_helpers.ex | 0 apps/{fz_http => web}/test/test_helper.exs | 0 asyncapi.yml | 265 - config/dev.exs | 10 +- docker-compose.yml | 2 +- mix.exs | 10 +- omnibus/.gitignore | 11 - omnibus/.kitchen.yml | 41 - omnibus/Berksfile | 14 - omnibus/Gemfile | 26 - omnibus/Gemfile.lock | 390 - omnibus/README.md | 124 - .../config/patches/bzip2/aix_makefile.patch | 11 - .../patches/bzip2/makefile_no_bins.patch | 77 - .../bzip2/makefile_take_env_vars.patch | 31 - .../patches/bzip2/soname_install_dir.patch | 11 - .../chef-bin/disable_license_enforce.patch | 10 - ...e-explicitly-adding-loopback-address.patch | 83 - .../patches/libedit/freebsd-vi-fix.patch | 24 - .../libedit/openbsd-weak-alias-fix.patch | 48 - ...ffi-3.2.1-disable-multi-os-directory.patch | 83 - .../patches/libffi/libffi-3.3-arm64.patch | 9608 ----------------- .../m4-1.4.18-glibc-change-work-around.patch | 115 - .../patches/ncurses/ncurses-5.9-gcc-5.patch | 46 - ...aris-xopen_source_extended-detection.patch | 11 - .../patches/ncurses/ncurses-clang.patch | 42 - omnibus/config/patches/ncurses/patch-aa | 23 - omnibus/config/patches/ncurses/patch-ab | 44 - omnibus/config/patches/ncurses/patch-ac | 40 - omnibus/config/patches/ncurses/patch-ad | 12 - .../patches/ncurses/patch-cxx_cursesf.h | 22 - .../patches/ncurses/patch-cxx_cursesm.h | 22 - .../patch-ncurses_tinfo_lib__baudrate.c | 24 - .../omnibus-ctl/skip-license-acceptance.patch | 12 - .../openssl-1.0.1f-do-not-build-docs.patch | 28 - .../openssl-1.0.1j-windows-relocate-dll.patch | 20 - ...1q-fix-compiler-flags-table-for-msys.patch | 20 - .../openssl/openssl-1.0.2x-darwin-arm64.patch | 54 - .../openssl-1.1.0f-do-not-install-docs.patch | 10 - .../perl/perl-5.18.1-remove_lnsl.patch | 441 - .../perl/perl-5.22.1-remove_lnsl.patch | 512 - .../perl/perl-5.30.0-remove_lnsl.patch | 518 - .../perl/perl-5.32.1-remove_lnsl.patch | 456 - .../perl/perl-5.34.0-remove_lnsl.patch | 516 - .../patches/pkg-config/openbsd-charset.patch | 19 - .../config/patches/postgresql/no_docs.patch | 19 - .../patches/python/disable_modules.patch | 14 - omnibus/config/patches/readline/8.1.patch | 75 - omnibus/config/patches/ruby/patch-configure | 103 - .../config/patches/ruby/ruby-aix-atomic.patch | 11 - .../patches/ruby/ruby-aix-configure.patch | 20 - .../patches/ruby/ruby-aix-vm-core.patch | 14 - .../ruby/ruby-disable-copy-file-range.patch | 13 - .../ruby-fix-reserve-stack-segfault.patch | 12 - .../patches/ruby/ruby-freebsd-9-zlib.patch | 0 omnibus/config/patches/ruby/ruby-mkmf.patch | 29 - .../ruby/ruby-no-stack-protector.patch | 13 - .../patches/ruby/ruby-openssl-1.0.1c.patch | 42 - .../ruby-solaris-linux-socket-compat.patch | 42 - .../patches/ruby/ruby-sparc-1.9.3-c99.patch | 20 - .../ruby/ruby_aix_1_9_3_448_ssl_EAGAIN.patch | 58 - .../ruby/ruby_aix_2_1_3_ssl_EAGAIN.patch | 19 - .../patches/ruby/ruby_aix_openssl.patch | 10 - omnibus/config/patches/ruby/rvm-cflags.patch | 27 - .../ruby/thread-memory-allocations-2.7.patch | 256 - .../rubygems/license/add-license-file.patch | 60 - omnibus/config/patches/runit/log-status.patch | 13 - .../patches/zlib/zlib-windows-relocate.patch | 19 - omnibus/config/projects/firezone.rb | 57 - omnibus/config/software/acme.rb | 19 - omnibus/config/software/autoconf.rb | 47 - omnibus/config/software/automake.rb | 52 - omnibus/config/software/bison.rb | 41 - omnibus/config/software/bzip2.rb | 57 - omnibus/config/software/cacerts.rb | 52 - omnibus/config/software/config_guess.rb | 39 - omnibus/config/software/elixir.rb | 46 - omnibus/config/software/erlang.rb | 156 - omnibus/config/software/firezone-cookbooks.rb | 70 - omnibus/config/software/firezone-ctl.rb | 48 - omnibus/config/software/firezone-scripts.rb | 34 - omnibus/config/software/firezone.rb | 69 - omnibus/config/software/flex.rb | 43 - omnibus/config/software/gawk.rb | 40 - omnibus/config/software/gettext.rb | 56 - omnibus/config/software/gmp.rb | 48 - omnibus/config/software/icu.rb | 29 - omnibus/config/software/libedit.rb | 68 - omnibus/config/software/libffi.rb | 64 - omnibus/config/software/libiconv.rb | 55 - omnibus/config/software/liblzma.rb | 60 - omnibus/config/software/libmnl.rb | 37 - omnibus/config/software/libnftnl.rb | 37 - omnibus/config/software/libossp-uuid.rb | 49 - omnibus/config/software/libtool.rb | 58 - omnibus/config/software/libxml2.rb | 63 - omnibus/config/software/libyaml.rb | 48 - omnibus/config/software/linenoise.rb | 36 - omnibus/config/software/m4.rb | 43 - omnibus/config/software/ncurses.rb | 160 - omnibus/config/software/nftables.rb | 54 - omnibus/config/software/nginx.rb | 60 - omnibus/config/software/omnibus-ctl.rb | 47 - omnibus/config/software/openssl.rb | 177 - omnibus/config/software/pcre.rb | 54 - omnibus/config/software/perl-thread-queue.rb | 44 - omnibus/config/software/perl.rb | 78 - omnibus/config/software/pkg-config.rb | 66 - omnibus/config/software/postgresql.rb | 79 - omnibus/config/software/readline.rb | 39 - omnibus/config/software/ruby.rb | 247 - omnibus/config/software/rubygems.rb | 88 - omnibus/config/software/runit.rb | 77 - omnibus/config/software/zlib.rb | 85 - .../templates/firezone-ctl/firezone-ctl.erb | 34 - .../config/templates/runit/runsvdir-start.erb | 42 - .../cookbooks/firezone/.delivery/project.toml | 32 - omnibus/cookbooks/firezone/.gitignore | 24 - omnibus/cookbooks/firezone/Berksfile | 8 - omnibus/cookbooks/firezone/CHANGELOG.md | 10 - omnibus/cookbooks/firezone/Gemfile | 7 - omnibus/cookbooks/firezone/LICENSE | 201 - omnibus/cookbooks/firezone/Policyfile.rb | 20 - omnibus/cookbooks/firezone/README.md | 3 - .../cookbooks/firezone/attributes/default.rb | 590 - omnibus/cookbooks/firezone/chefignore | 115 - .../default/ctl-commands/create_admin.rb | 51 - .../default/ctl-commands/force_renewal.rb | 48 - .../files/default/ctl-commands/reconfigure.rb | 44 - .../default/ctl-commands/reset_network.rb | 18 - .../default/ctl-commands/stop_renewal.rb | 48 - .../files/default/ctl-commands/teardown.rb | 18 - .../files/default/ctl-commands/version.rb | 27 - omnibus/cookbooks/firezone/kitchen.yml | 32 - .../cookbooks/firezone/libraries/config.rb | 314 - omnibus/cookbooks/firezone/metadata.rb | 25 - omnibus/cookbooks/firezone/recipes/acme.rb | 103 - omnibus/cookbooks/firezone/recipes/app.rb | 64 - omnibus/cookbooks/firezone/recipes/config.rb | 108 - .../firezone/recipes/create_admin.rb | 49 - .../cookbooks/firezone/recipes/database.rb | 58 - omnibus/cookbooks/firezone/recipes/default.rb | 46 - .../firezone/recipes/force_renewal.rb | 25 - .../firezone/recipes/log_management.rb | 54 - omnibus/cookbooks/firezone/recipes/network.rb | 56 - omnibus/cookbooks/firezone/recipes/nginx.rb | 102 - omnibus/cookbooks/firezone/recipes/phoenix.rb | 95 - .../cookbooks/firezone/recipes/postgresql.rb | 56 - omnibus/cookbooks/firezone/recipes/setcap.rb | 27 - .../cookbooks/firezone/recipes/show_config.rb | 26 - omnibus/cookbooks/firezone/recipes/ssl.rb | 103 - .../firezone/recipes/stop_renewal.rb | 21 - .../cookbooks/firezone/recipes/teardown.rb | 33 - .../cookbooks/firezone/recipes/telemetry.rb | 26 - .../cookbooks/firezone/recipes/wireguard.rb | 29 - .../firezone/templates/firezone.rb.erb | 3 - .../firezone/templates/logrotate-rule.erb | 15 - .../firezone/templates/logrotate.conf.erb | 4 - .../firezone/templates/logrotate.cron.erb | 6 - .../firezone/templates/nginx.conf.erb | 101 - .../firezone/templates/pg_hba.conf.erb | 73 - .../firezone/templates/phoenix.nginx.conf.erb | 133 - .../firezone/templates/postgresql.conf.erb | 22 - .../firezone/templates/redirect.conf.erb | 18 - .../firezone/templates/ssl-signing.conf.erb | 12 - .../firezone/templates/sv-nginx-log-run.erb | 3 - .../firezone/templates/sv-nginx-run.erb | 8 - .../firezone/templates/sv-phoenix-finish.erb | 46 - .../firezone/templates/sv-phoenix-log-run.erb | 3 - .../firezone/templates/sv-phoenix-run.erb | 18 - .../firezone/templates/sv-phoenix-t.erb | 5 - .../templates/sv-postgresql-log-run.erb | 3 - .../firezone/templates/sv-postgresql-run.erb | 8 - .../firezone/templates/sv-postgresql-t.erb | 5 - .../templates/sv-wireguard-log-run.erb | 3 - .../firezone/templates/sv-wireguard-run.erb | 18 - .../test/integration/default/default_test.rb | 18 - .../files/firezone-scripts/symlink_ctl_cmds | 26 - omnibus/files/firezone-scripts/wireguard | 56 - omnibus/omnibus.rb | 66 - omnibus/package-scripts/firezone/postinst | 58 - omnibus/package-scripts/firezone/postrm | 34 - omnibus/package-scripts/firezone/preinst | 73 - omnibus/package-scripts/firezone/prerm | 40 - www/docs/administer/regen-keys.mdx | 17 - www/docs/administer/troubleshoot.mdx | 54 +- www/docs/authenticate/saml/README.mdx | 12 - www/docs/deploy/README.mdx | 17 - .../deploy/advanced/external-database.mdx | 22 - www/docs/deploy/configure.mdx | 17 - www/docs/deploy/omnibus/README.mdx | 195 - .../deploy/omnibus/supported-platforms.mdx | 121 - www/docs/reference/telemetry.mdx | 10 - 678 files changed, 43 insertions(+), 24119 deletions(-) delete mode 100644 .github/workflows/omnibus_build.yml delete mode 100644 .github/workflows/omnibus_publish.yml delete mode 100644 .rubocop.yml delete mode 100644 Gemfile delete mode 100644 Gemfile.lock rename apps/{fz_http/lib => domain}/fz_http.ex (100%) rename apps/{fz_http/lib => domain}/fz_http/api_tokens.ex (100%) rename apps/{fz_http/lib => domain}/fz_http/api_tokens/api_token.ex (100%) rename apps/{fz_http/lib => domain}/fz_http/api_tokens/api_token/changeset.ex (100%) rename apps/{fz_http/lib => domain}/fz_http/api_tokens/api_token/query.ex (100%) rename apps/{fz_http/lib => domain}/fz_http/api_tokens/authorizer.ex (100%) rename apps/{fz_http/lib => domain}/fz_http/application.ex (100%) rename apps/{fz_http/lib => domain}/fz_http/auth.ex (100%) rename apps/{fz_http/lib => domain}/fz_http/auth/authorizer.ex (100%) rename apps/{fz_http/lib => domain}/fz_http/auth/context.ex (100%) rename apps/{fz_http/lib => domain}/fz_http/auth/mfa.ex (100%) rename apps/{fz_http/lib => domain}/fz_http/auth/mfa/method.ex (100%) rename apps/{fz_http/lib => domain}/fz_http/auth/mfa/method/changeset.ex (100%) rename apps/{fz_http/lib => domain}/fz_http/auth/mfa/method/query.ex (100%) rename apps/{fz_http/lib => domain}/fz_http/auth/oidc.ex (100%) rename apps/{fz_http/lib => domain}/fz_http/auth/oidc/connection.ex (100%) rename apps/{fz_http/lib => domain}/fz_http/auth/oidc/connection/changeset.ex (100%) rename apps/{fz_http/lib => domain}/fz_http/auth/oidc/connection/query.ex (100%) rename apps/{fz_http/lib => domain}/fz_http/auth/oidc/refresh_manager.ex (100%) rename apps/{fz_http/lib => domain}/fz_http/auth/oidc/refresher.ex (100%) rename apps/{fz_http/lib => domain}/fz_http/auth/permission.ex (100%) rename apps/{fz_http/lib => domain}/fz_http/auth/role.ex (100%) rename apps/{fz_http/lib => domain}/fz_http/auth/roles.ex (100%) rename apps/{fz_http/lib => domain}/fz_http/auth/saml/start_proxy.ex (100%) rename apps/{fz_http/lib => domain}/fz_http/auth/subject.ex (100%) rename apps/{fz_http/lib => domain}/fz_http/config.ex (100%) rename apps/{fz_http/lib => domain}/fz_http/config/authorizer.ex (100%) rename apps/{fz_http/lib => domain}/fz_http/config/caster.ex (100%) rename apps/{fz_http/lib => domain}/fz_http/config/configuration.ex (100%) rename apps/{fz_http/lib => domain}/fz_http/config/configuration/changeset.ex (100%) rename apps/{fz_http/lib => domain}/fz_http/config/configuration/openid_connect_provider.ex (100%) rename apps/{fz_http/lib => domain}/fz_http/config/configuration/saml_identity_provider.ex (100%) rename apps/{fz_http/lib => domain}/fz_http/config/definition.ex (100%) rename apps/{fz_http/lib => domain}/fz_http/config/definitions.ex (100%) rename apps/{fz_http/lib => domain}/fz_http/config/dumper.ex (100%) rename apps/{fz_http/lib => domain}/fz_http/config/errors.ex (100%) rename apps/{fz_http/lib => domain}/fz_http/config/fetcher.ex (100%) rename apps/{fz_http/lib => domain}/fz_http/config/logo.ex (100%) rename apps/{fz_http/lib => domain}/fz_http/config/resolver.ex (100%) rename apps/{fz_http/lib => domain}/fz_http/config/validator.ex (100%) rename apps/{fz_http/lib => domain}/fz_http/connectivity_checks.ex (100%) rename apps/{fz_http/lib => domain}/fz_http/connectivity_checks/authorizer.ex (100%) rename apps/{fz_http/lib => domain}/fz_http/connectivity_checks/connectivity_check.ex (100%) rename apps/{fz_http/lib => domain}/fz_http/connectivity_checks/connectivity_check/changeset.ex (100%) rename apps/{fz_http/lib => domain}/fz_http/connectivity_checks/connectivity_check/query.ex (100%) rename apps/{fz_http/lib => domain}/fz_http/connectivity_checks/poller.ex (100%) rename apps/{fz_http/lib => domain}/fz_http/crypto.ex (100%) rename apps/{fz_http/lib => domain}/fz_http/devices.ex (100%) rename apps/{fz_http/lib => domain}/fz_http/devices/authorizer.ex (100%) rename apps/{fz_http/lib => domain}/fz_http/devices/device.ex (100%) rename apps/{fz_http/lib => domain}/fz_http/devices/device/changeset.ex (100%) rename apps/{fz_http/lib => domain}/fz_http/devices/device/query.ex (100%) rename apps/{fz_http/lib => domain}/fz_http/devices/stats_updater.ex (100%) rename apps/{fz_http/lib => domain}/fz_http/encrypted/binary.ex (100%) rename apps/{fz_http/lib => domain}/fz_http/encrypted/map.ex (100%) rename apps/{fz_http/lib => domain}/fz_http/name_generator.ex (100%) rename apps/{fz_http/lib => domain}/fz_http/release.ex (100%) rename apps/{fz_http/lib => domain}/fz_http/repo.ex (100%) rename apps/{fz_http/lib => domain}/fz_http/repo/notifier.ex (100%) rename apps/{fz_http/lib => domain}/fz_http/rules.ex (100%) rename apps/{fz_http/lib => domain}/fz_http/rules/authorizer.ex (100%) rename apps/{fz_http/lib => domain}/fz_http/rules/rule.ex (100%) rename apps/{fz_http/lib => domain}/fz_http/rules/rule/changeset.ex (100%) rename apps/{fz_http/lib => domain}/fz_http/rules/rule/query.ex (100%) rename apps/{fz_http/lib => domain}/fz_http/server.ex (100%) rename apps/{fz_http/lib => domain}/fz_http/telemetry.ex (100%) rename apps/{fz_http/lib => domain}/fz_http/telemetry/posthog.ex (100%) rename apps/{fz_http/lib => domain}/fz_http/telemetry/timer.ex (100%) rename apps/{fz_http/lib => domain}/fz_http/types/cidr.ex (100%) rename apps/{fz_http/lib => domain}/fz_http/types/inet.ex (100%) rename apps/{fz_http/lib => domain}/fz_http/types/int4range.ex (100%) rename apps/{fz_http/lib => domain}/fz_http/types/ip.ex (100%) rename apps/{fz_http/lib => domain}/fz_http/types/ip_port.ex (100%) rename apps/{fz_http/lib => domain}/fz_http/types/protocols.ex (100%) rename apps/{fz_http/lib => domain}/fz_http/users.ex (100%) rename apps/{fz_http/lib => domain}/fz_http/users/authorizer.ex (100%) rename apps/{fz_http/lib => domain}/fz_http/users/user.ex (100%) rename apps/{fz_http/lib => domain}/fz_http/users/user/changeset.ex (100%) rename apps/{fz_http/lib => domain}/fz_http/users/user/query.ex (100%) rename apps/{fz_http/lib => domain}/fz_http/validator.ex (100%) rename apps/{fz_http/lib => domain}/fz_http/vault.ex (100%) rename apps/{fz_http/lib => domain}/fz_http/vpn_session_scheduler.ex (100%) delete mode 100644 apps/fz_http/lib/fz_http/events.ex delete mode 100644 apps/fz_http/lib/fz_http/notifications.ex delete mode 100644 apps/fz_vpn/.formatter.exs delete mode 100644 apps/fz_vpn/.gitignore delete mode 100644 apps/fz_vpn/README.md delete mode 100644 apps/fz_vpn/coveralls.json delete mode 100644 apps/fz_vpn/lib/fz_vpn.ex delete mode 100644 apps/fz_vpn/lib/fz_vpn/application.ex delete mode 100644 apps/fz_vpn/lib/fz_vpn/interface.ex delete mode 100644 apps/fz_vpn/lib/fz_vpn/interface/wg_adapter.ex delete mode 100644 apps/fz_vpn/lib/fz_vpn/interface/wg_adapter/live.ex delete mode 100644 apps/fz_vpn/lib/fz_vpn/interface/wg_adapter/sandbox.ex delete mode 100644 apps/fz_vpn/lib/fz_vpn/keypair.ex delete mode 100644 apps/fz_vpn/lib/fz_vpn/server.ex delete mode 100644 apps/fz_vpn/lib/fz_vpn/stats_push_service.ex delete mode 100644 apps/fz_vpn/mix.exs delete mode 100644 apps/fz_vpn/test/fixtures/.gitkeep delete mode 100644 apps/fz_vpn/test/fz_vpn/interface_test.exs delete mode 100644 apps/fz_vpn/test/fz_vpn/server_test.exs delete mode 100644 apps/fz_vpn/test/fz_vpn/stats_push_service_test.exs delete mode 100644 apps/fz_vpn/test/fz_vpn_test.exs delete mode 100644 apps/fz_vpn/test/test_helper.exs delete mode 100644 apps/fz_wall/.formatter.exs delete mode 100644 apps/fz_wall/.gitignore delete mode 100644 apps/fz_wall/README.md delete mode 100644 apps/fz_wall/lib/fz_wall.ex delete mode 100644 apps/fz_wall/lib/fz_wall/application.ex delete mode 100644 apps/fz_wall/lib/fz_wall/cli.ex delete mode 100644 apps/fz_wall/lib/fz_wall/cli/helpers/nft.ex delete mode 100644 apps/fz_wall/lib/fz_wall/cli/helpers/sets.ex delete mode 100644 apps/fz_wall/lib/fz_wall/cli/live.ex delete mode 100644 apps/fz_wall/lib/fz_wall/cli/sandbox.ex delete mode 100644 apps/fz_wall/lib/fz_wall/server.ex delete mode 100644 apps/fz_wall/lib/fz_wall/shell.ex delete mode 100644 apps/fz_wall/mix.exs delete mode 100644 apps/fz_wall/test/cli/helpers/nft_test.exs delete mode 100644 apps/fz_wall/test/cli/live_test.exs delete mode 100644 apps/fz_wall/test/fz_wall_test.exs delete mode 100644 apps/fz_wall/test/test_helper.exs rename apps/{fz_http => web}/.formatter.exs (100%) rename apps/{fz_http => web}/.gitignore (100%) rename apps/{fz_http => web}/README.md (100%) rename apps/{fz_http => web}/assets/.babelrc (100%) rename apps/{fz_http => web}/assets/config.dev.js (100%) rename apps/{fz_http => web}/assets/config.prod.js (100%) rename apps/{fz_http => web}/assets/css/app.scss (100%) rename apps/{fz_http => web}/assets/css/email.scss (100%) rename apps/{fz_http => web}/assets/css/main.scss (100%) rename apps/{fz_http => web}/assets/css/tables.scss (100%) rename apps/{fz_http => web}/assets/esbuild.js (100%) rename apps/{fz_http => web}/assets/js/admin.js (100%) rename apps/{fz_http => web}/assets/js/crypto.js (100%) rename apps/{fz_http => web}/assets/js/event_listeners.js (100%) rename apps/{fz_http => web}/assets/js/hooks.js (100%) rename apps/{fz_http => web}/assets/js/live_view.js (100%) rename apps/{fz_http => web}/assets/js/qrcode.js (100%) rename apps/{fz_http => web}/assets/js/root.js (100%) rename apps/{fz_http => web}/assets/js/unprivileged.js (100%) rename apps/{fz_http => web}/assets/js/util.js (100%) rename apps/{fz_http => web}/assets/js/wg_conf.js (100%) rename apps/{fz_http => web}/assets/local_modules/admin-one-bulma-dashboard/.editorconfig (100%) rename apps/{fz_http => web}/assets/local_modules/admin-one-bulma-dashboard/.gitattributes (100%) rename apps/{fz_http => web}/assets/local_modules/admin-one-bulma-dashboard/.gitignore (100%) rename apps/{fz_http => web}/assets/local_modules/admin-one-bulma-dashboard/.tool-versions (100%) rename apps/{fz_http => web}/assets/local_modules/admin-one-bulma-dashboard/LICENSE (100%) rename apps/{fz_http => web}/assets/local_modules/admin-one-bulma-dashboard/README.md (100%) rename apps/{fz_http => web}/assets/local_modules/admin-one-bulma-dashboard/package.json (100%) rename apps/{fz_http => web}/assets/local_modules/admin-one-bulma-dashboard/src/js/main.js (100%) rename apps/{fz_http => web}/assets/local_modules/admin-one-bulma-dashboard/src/scss/_aside.scss (100%) rename apps/{fz_http => web}/assets/local_modules/admin-one-bulma-dashboard/src/scss/_card.scss (100%) rename apps/{fz_http => web}/assets/local_modules/admin-one-bulma-dashboard/src/scss/_footer.scss (100%) rename apps/{fz_http => web}/assets/local_modules/admin-one-bulma-dashboard/src/scss/_form.scss (100%) rename apps/{fz_http => web}/assets/local_modules/admin-one-bulma-dashboard/src/scss/_hero-bar.scss (100%) rename apps/{fz_http => web}/assets/local_modules/admin-one-bulma-dashboard/src/scss/_main-section.scss (100%) rename apps/{fz_http => web}/assets/local_modules/admin-one-bulma-dashboard/src/scss/_misc.scss (100%) rename apps/{fz_http => web}/assets/local_modules/admin-one-bulma-dashboard/src/scss/_mixins.scss (100%) rename apps/{fz_http => web}/assets/local_modules/admin-one-bulma-dashboard/src/scss/_modal.scss (100%) rename apps/{fz_http => web}/assets/local_modules/admin-one-bulma-dashboard/src/scss/_nav-bar.scss (100%) rename apps/{fz_http => web}/assets/local_modules/admin-one-bulma-dashboard/src/scss/_table.scss (100%) rename apps/{fz_http => web}/assets/local_modules/admin-one-bulma-dashboard/src/scss/_theme-firezone.scss (100%) rename apps/{fz_http => web}/assets/local_modules/admin-one-bulma-dashboard/src/scss/_tiles.scss (100%) rename apps/{fz_http => web}/assets/local_modules/admin-one-bulma-dashboard/src/scss/_title-bar.scss (100%) rename apps/{fz_http => web}/assets/local_modules/admin-one-bulma-dashboard/src/scss/libs/_all.scss (100%) rename apps/{fz_http => web}/assets/local_modules/admin-one-bulma-dashboard/src/scss/main.scss (100%) rename apps/{fz_http => web}/assets/package.json (100%) rename apps/{fz_http => web}/assets/postcss.config.js (100%) rename apps/{fz_http => web}/assets/yarn.lock (100%) rename apps/{fz_http => web}/coveralls.json (100%) rename apps/{fz_http => web}/lib/fz_http_web.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/auth/html/authentication.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/auth/html/error_handler.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/auth/html/pipeline.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/auth/json/authentication.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/auth/json/error_handler.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/auth/json/pipeline.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/authorization_helpers.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/channels/notification_channel.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/controller_helpers.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/controllers/auth_controller.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/controllers/browser_controller.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/controllers/debug_controller.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/controllers/json/configuration_controller.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/controllers/json/device_controller.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/controllers/json/fallback_controller.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/controllers/json/rule_controller.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/controllers/json/user_controller.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/controllers/root_controller.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/controllers/user_controller.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/doc_helpers.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/endpoint.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/error_helpers.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/gettext.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/header_helpers.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/live/connectivity_check_live/index.html.heex (100%) rename apps/{fz_http => web}/lib/fz_http_web/live/connectivity_check_live/index_live.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/live/device_live/admin/index.html.heex (100%) rename apps/{fz_http => web}/lib/fz_http_web/live/device_live/admin/index_live.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/live/device_live/admin/show.html.heex (100%) rename apps/{fz_http => web}/lib/fz_http_web/live/device_live/admin/show_live.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/live/device_live/new_form_component.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/live/device_live/new_form_component.html.heex (100%) rename apps/{fz_http => web}/lib/fz_http_web/live/device_live/unprivileged/index.html.heex (100%) rename apps/{fz_http => web}/lib/fz_http_web/live/device_live/unprivileged/index_live.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/live/device_live/unprivileged/show.html.heex (100%) rename apps/{fz_http => web}/lib/fz_http_web/live/device_live/unprivileged/show_live.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/live/hooks/allow_ecto_sandbox.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/live/hooks/live_auth.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/live/hooks/live_mfa.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/live/hooks/live_nav.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/live/logo_component.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/live/mfa_live/auth_live.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/live/mfa_live/register_component.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/live/mfa_live/register_steps_component.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/live/modal_component.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/live/notifications_live/badge.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/live/notifications_live/badge.html.heex (100%) rename apps/{fz_http => web}/lib/fz_http_web/live/notifications_live/index.html.heex (100%) rename apps/{fz_http => web}/lib/fz_http_web/live/notifications_live/index_live.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/live/oidc_live/connections_table_component.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/live/oidc_live/connections_table_component.html.heex (100%) rename apps/{fz_http => web}/lib/fz_http_web/live/rule_live/index.html.heex (100%) rename apps/{fz_http => web}/lib/fz_http_web/live/rule_live/index_live.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/live/rule_live/rule_list_component.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/live/rule_live/rule_list_component.html.heex (100%) rename apps/{fz_http => web}/lib/fz_http_web/live/setting_live/account.html.heex (100%) rename apps/{fz_http => web}/lib/fz_http_web/live/setting_live/account_form_component.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/live/setting_live/account_form_component.html.heex (100%) rename apps/{fz_http => web}/lib/fz_http_web/live/setting_live/account_live.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/live/setting_live/client_defaults.html.heex (100%) rename apps/{fz_http => web}/lib/fz_http_web/live/setting_live/client_defaults_form_component.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/live/setting_live/client_defaults_form_component.html.heex (100%) rename apps/{fz_http => web}/lib/fz_http_web/live/setting_live/client_defaults_live.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/live/setting_live/customization.html.heex (100%) rename apps/{fz_http => web}/lib/fz_http_web/live/setting_live/customization_live.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/live/setting_live/new_api_token_component.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/live/setting_live/oidc_form_component.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/live/setting_live/saml_form_component.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/live/setting_live/security.html.heex (100%) rename apps/{fz_http => web}/lib/fz_http_web/live/setting_live/security_live.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/live/setting_live/show_api_token_component.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/live/setting_live/unprivileged/account.html.heex (100%) rename apps/{fz_http => web}/lib/fz_http_web/live/setting_live/unprivileged/account_form_component.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/live/setting_live/unprivileged/account_form_component.html.heex (100%) rename apps/{fz_http => web}/lib/fz_http_web/live/setting_live/unprivileged/account_live.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/live/sidebar_component.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/live/user_live/form_component.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/live/user_live/form_component.html.heex (100%) rename apps/{fz_http => web}/lib/fz_http_web/live/user_live/index.html.heex (100%) rename apps/{fz_http => web}/lib/fz_http_web/live/user_live/index_live.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/live/user_live/show.html.heex (100%) rename apps/{fz_http => web}/lib/fz_http_web/live/user_live/show_live.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/live/user_live/vpn_connection_component.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/live/user_live/vpn_status_component.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/live_helpers.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/mailer.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/mailer/auth_email.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/mailer/noop_adapter.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/mailer/templates/auth_email/magic_link.html.heex (100%) rename apps/{fz_http => web}/lib/fz_http_web/mailer/templates/auth_email/magic_link.text.eex (100%) rename apps/{fz_http => web}/lib/fz_http_web/oauth/pkce.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/oidc/state.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/plug/path_prefix.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/plug/require_local_authentication.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/plug/samly_target_url.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/presence.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/proxy_headers.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/router.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/sandbox.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/session.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/sockets/user_socket.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/templates/auth/request.html.heex (100%) rename apps/{fz_http => web}/lib/fz_http_web/templates/auth/reset_password.html.heex (100%) rename apps/{fz_http => web}/lib/fz_http_web/templates/browser/browserconfig.xml.eex (100%) rename apps/{fz_http => web}/lib/fz_http_web/templates/layout/admin.html.heex (100%) rename apps/{fz_http => web}/lib/fz_http_web/templates/layout/app.html.heex (100%) rename apps/{fz_http => web}/lib/fz_http_web/templates/layout/email.html.heex (100%) rename apps/{fz_http => web}/lib/fz_http_web/templates/layout/live.html.heex (100%) rename apps/{fz_http => web}/lib/fz_http_web/templates/layout/root.html.heex (100%) rename apps/{fz_http => web}/lib/fz_http_web/templates/layout/unprivileged.html.heex (100%) rename apps/{fz_http => web}/lib/fz_http_web/templates/root/auth.html.heex (100%) rename apps/{fz_http => web}/lib/fz_http_web/templates/shared/device_details.html.heex (100%) rename apps/{fz_http => web}/lib/fz_http_web/templates/shared/devices_table.html.heex (100%) rename apps/{fz_http => web}/lib/fz_http_web/templates/shared/flash.html.heex (100%) rename apps/{fz_http => web}/lib/fz_http_web/templates/shared/head.html.heex (100%) rename apps/{fz_http => web}/lib/fz_http_web/templates/shared/heading.html.heex (100%) rename apps/{fz_http => web}/lib/fz_http_web/templates/shared/mfa_methods_table.html.heex (100%) rename apps/{fz_http => web}/lib/fz_http_web/templates/shared/password_field.html.heex (100%) rename apps/{fz_http => web}/lib/fz_http_web/templates/shared/show_device.html.heex (100%) rename apps/{fz_http => web}/lib/fz_http_web/templates/shared/socket_token_headers.html.heex (100%) rename apps/{fz_http => web}/lib/fz_http_web/templates/shared/submit_button.html.heex (100%) rename apps/{fz_http => web}/lib/fz_http_web/templates/shared/user_details.html.heex (100%) rename apps/{fz_http => web}/lib/fz_http_web/user_from_auth.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/views/auth_view.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/views/browser_view.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/views/error_view.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/views/json/changeset_view.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/views/json/configuration_view.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/views/json/device_view.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/views/json/openid_connect_provider_view.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/views/json/rule_view.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/views/json/saml_identity_provider_view.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/views/json/user_view.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/views/layout_view.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/views/root_view.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/views/rule_view.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/views/shared_view.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/views/user_view.ex (100%) rename apps/{fz_http => web}/lib/fz_http_web/views/wireguard_config_view.ex (100%) rename apps/{fz_http => web}/mix.exs (100%) rename apps/{fz_http => web}/priv/cert/saml_selfsigned.pem (100%) rename apps/{fz_http => web}/priv/cert/saml_selfsigned_key.pem (100%) rename apps/{fz_http => web}/priv/gettext/en/LC_MESSAGES/errors.po (100%) rename apps/{fz_http => web}/priv/gettext/errors.pot (100%) rename apps/{fz_http => web}/priv/repo/migrations/20200225005454_create_users.exs (100%) rename apps/{fz_http => web}/priv/repo/migrations/20200228145810_create_devices.exs (100%) rename apps/{fz_http => web}/priv/repo/migrations/20200228154815_create_rules.exs (100%) rename apps/{fz_http => web}/priv/repo/migrations/20210929172417_add_dns_servers_to_devices.exs (100%) rename apps/{fz_http => web}/priv/repo/migrations/20211116172808_create_connectivity_checks.exs (100%) rename apps/{fz_http => web}/priv/repo/migrations/20211116173236_create_settings.exs (100%) rename apps/{fz_http => web}/priv/repo/migrations/20211203012238_change_device_column_defaults.exs (100%) rename apps/{fz_http => web}/priv/repo/migrations/20211216155557_add_config_token_to_devices.exs (100%) rename apps/{fz_http => web}/priv/repo/migrations/20211217003247_add_persistent_keepalives.exs (100%) rename apps/{fz_http => web}/priv/repo/migrations/20211221183311_add_role_to_users.exs (100%) rename apps/{fz_http => web}/priv/repo/migrations/20211223161545_add_require_auth_for_vpn_setting.exs (100%) rename apps/{fz_http => web}/priv/repo/migrations/20220103175026_add_inets_to_devices.exs (100%) rename apps/{fz_http => web}/priv/repo/migrations/20220111004847_add_mtu_to_devices.exs (100%) rename apps/{fz_http => web}/priv/repo/migrations/20220124162404_add_uuids.exs (100%) rename apps/{fz_http => web}/priv/repo/migrations/20220127021835_rename_persistent_keepalives.exs (100%) rename apps/{fz_http => web}/priv/repo/migrations/20220127191440_rename_dns_servers_to_dns.exs (100%) rename apps/{fz_http => web}/priv/repo/migrations/20220208184257_settings_to_sites.exs (100%) rename apps/{fz_http => web}/priv/repo/migrations/20220209005201_rename_use_default_to_use_site.exs (100%) rename apps/{fz_http => web}/priv/repo/migrations/20220211201727_remove_private_keys.exs (100%) rename apps/{fz_http => web}/priv/repo/migrations/20220219165023_add_key_regenerated_at.exs (100%) rename apps/{fz_http => web}/priv/repo/migrations/20220227215313_add_last_signed_in_method_to_user.exs (100%) rename apps/{fz_http => web}/priv/repo/migrations/20220412144151_add_psk_to_devices.exs (100%) rename apps/{fz_http => web}/priv/repo/migrations/20220419172036_add_stats_to_devices.exs (100%) rename apps/{fz_http => web}/priv/repo/migrations/20220427140943_add_description_to_devices.exs (100%) rename apps/{fz_http => web}/priv/repo/migrations/20220516063916_change_allowed_ips_to_text.exs (100%) rename apps/{fz_http => web}/priv/repo/migrations/20220519034545_create_oidc_connections.exs (100%) rename apps/{fz_http => web}/priv/repo/migrations/20220520072323_add_disabled_at_to_user.exs (100%) rename apps/{fz_http => web}/priv/repo/migrations/20220530073152_create_mfa_methods.exs (100%) rename apps/{fz_http => web}/priv/repo/migrations/20220609232854_change_refresh_token_to_text.exs (100%) rename apps/{fz_http => web}/priv/repo/migrations/20220614192937_add_user_id_to_rules.exs (100%) rename apps/{fz_http => web}/priv/repo/migrations/20220713050742_create_configurations.exs (100%) rename apps/{fz_http => web}/priv/repo/migrations/20220719014442_add_auth_configs.exs (100%) rename apps/{fz_http => web}/priv/repo/migrations/20220721164925_add_device_rule_user_notify_triggers.exs (100%) rename apps/{fz_http => web}/priv/repo/migrations/20220726205646_add_rule_port_range.exs (100%) rename apps/{fz_http => web}/priv/repo/migrations/20220810002432_add_unprivileged_device_configuration.exs (100%) rename apps/{fz_http => web}/priv/repo/migrations/20220831060724_add_saml_identity_providers_to_configuration.exs (100%) rename apps/{fz_http => web}/priv/repo/migrations/20221012123308_move_auto_create_users_to_providers.exs (100%) rename apps/{fz_http => web}/priv/repo/migrations/20221129002233_update_on_delete_behavior.exs (100%) rename apps/{fz_http => web}/priv/repo/migrations/20221223190406_migrate_pks_to_uuid.exs (100%) rename apps/{fz_http => web}/priv/repo/migrations/20221223223357_migrate_datetimes_to_timestamptz.exs (100%) rename apps/{fz_http => web}/priv/repo/migrations/20221223223931_order_connectivity_checks_inserted_at_index.exs (100%) rename apps/{fz_http => web}/priv/repo/migrations/20221224210654_fix_sites_nullable_fields.exs (100%) rename apps/{fz_http => web}/priv/repo/migrations/20221226044850_create_api_tokens.exs (100%) rename apps/{fz_http => web}/priv/repo/migrations/20221226143651_move_sites_fields_to_configurations.exs (100%) rename apps/{fz_http => web}/priv/repo/migrations/20221226171558_rename_use_site_to_use_default.exs (100%) rename apps/{fz_http => web}/priv/repo/migrations/20221226193228_drop_sites.exs (100%) rename apps/{fz_http => web}/priv/repo/migrations/20221227181727_move_cache_fallbacks_to_configurations.exs (100%) rename apps/{fz_http => web}/priv/repo/migrations/20221229154115_migrate_providers_configs.exs (100%) rename apps/{fz_http => web}/priv/repo/migrations/20230104000803_add_users_sign_in_token_hash.exs (100%) rename apps/{fz_http => web}/priv/repo/migrations/20230104181853_change_users_email_to_citext.exs (100%) rename apps/{fz_http => web}/priv/repo/migrations/20230113184557_add_default_pks_values.exs (100%) rename apps/{fz_http => web}/priv/repo/migrations/20230116200524_add_not_null_to_mfa_methods.exs (100%) rename apps/{fz_http => web}/priv/repo/migrations/20230127164048_change_configurations_default_client_allowed_ips_type.exs (100%) rename apps/{fz_http => web}/priv/repo/migrations/20230203143621_change_mfa_methods_unique_index.exs (100%) rename apps/{fz_http => web}/priv/repo/migrations/20230206172556_change_dns_and_allowed_ips_to_inet_array.exs (100%) rename apps/{fz_http => web}/priv/repo/migrations/20230223175621_trim_dns_fields.exs (100%) rename apps/{fz_http => web}/priv/repo/migrations/20230317161258_remove_devices_key_regenerated_at.exs (100%) rename apps/{fz_http => web}/priv/repo/seeds.exs (100%) rename apps/{fz_http => web}/priv/static/images/android-chrome-192x192.png (100%) rename apps/{fz_http => web}/priv/static/images/android-chrome-512x512.png (100%) rename apps/{fz_http => web}/priv/static/images/apple-touch-icon.png (100%) rename apps/{fz_http => web}/priv/static/images/favicon-16x16.png (100%) rename apps/{fz_http => web}/priv/static/images/favicon-32x32.png (100%) rename apps/{fz_http => web}/priv/static/images/favicon.ico (100%) rename apps/{fz_http => web}/priv/static/images/logo-text.svg (100%) rename apps/{fz_http => web}/priv/static/images/logo.svg (100%) rename apps/{fz_http => web}/priv/static/images/mstile-150x150.png (100%) rename apps/{fz_http => web}/priv/static/robots.txt (100%) rename apps/{fz_http => web}/priv/static/site.webmanifest (100%) rename apps/{fz_http => web}/test/fz_http/api_tokens_test.exs (100%) rename apps/{fz_http => web}/test/fz_http/auth/mfa_test.exs (100%) rename apps/{fz_http => web}/test/fz_http/auth/oidc/refresher_test.exs (100%) rename apps/{fz_http => web}/test/fz_http/auth_test.exs (100%) rename apps/{fz_http => web}/test/fz_http/config/caster_test.exs (100%) rename apps/{fz_http => web}/test/fz_http/config/definition_test.exs (100%) rename apps/{fz_http => web}/test/fz_http/config/fetcher_test.exs (100%) rename apps/{fz_http => web}/test/fz_http/config/resolver_test.exs (100%) rename apps/{fz_http => web}/test/fz_http/config/validator_test.exs (100%) rename apps/{fz_http => web}/test/fz_http/config_test.exs (100%) rename apps/{fz_http => web}/test/fz_http/connectivity_checks/poller_test.exs (100%) rename apps/{fz_http => web}/test/fz_http/connectivity_checks_test.exs (100%) rename apps/{fz_http => web}/test/fz_http/crypto_test.exs (100%) rename apps/{fz_http => web}/test/fz_http/devices/device/query_test.exs (100%) rename apps/{fz_http => web}/test/fz_http/devices/stats_updater_test.exs (100%) rename apps/{fz_http => web}/test/fz_http/devices_test.exs (100%) rename apps/{fz_http => web}/test/fz_http/events_test.exs (100%) rename apps/{fz_http => web}/test/fz_http/name_generator_test.exs (100%) rename apps/{fz_http => web}/test/fz_http/notifications_test.exs (100%) rename apps/{fz_http => web}/test/fz_http/release_test.exs (100%) rename apps/{fz_http => web}/test/fz_http/repo/notifier_test.exs (100%) rename apps/{fz_http => web}/test/fz_http/rules_test.exs (100%) rename apps/{fz_http => web}/test/fz_http/telemetry_test.exs (100%) rename apps/{fz_http => web}/test/fz_http/types/cidr_test.exs (100%) rename apps/{fz_http => web}/test/fz_http/users_test.exs (100%) rename apps/{fz_http => web}/test/fz_http_web/acceptance/admin_test.exs (100%) rename apps/{fz_http => web}/test/fz_http_web/acceptance/authentication_test.exs (100%) rename apps/{fz_http => web}/test/fz_http_web/acceptance/unprivileged_user_test.exs (100%) rename apps/{fz_http => web}/test/fz_http_web/auth/json/authentication_test.exs (100%) rename apps/{fz_http => web}/test/fz_http_web/channels/notification_channel_test.exs (100%) rename apps/{fz_http => web}/test/fz_http_web/controllers/auth_controller_test.exs (100%) rename apps/{fz_http => web}/test/fz_http_web/controllers/browser_controller_test.exs (100%) rename apps/{fz_http => web}/test/fz_http_web/controllers/json/configuration_controller_test.exs (100%) rename apps/{fz_http => web}/test/fz_http_web/controllers/json/device_controller_test.exs (100%) rename apps/{fz_http => web}/test/fz_http_web/controllers/json/rule_controller_test.exs (100%) rename apps/{fz_http => web}/test/fz_http_web/controllers/json/user_controller_test.exs (100%) rename apps/{fz_http => web}/test/fz_http_web/controllers/user_controller_test.exs (100%) rename apps/{fz_http => web}/test/fz_http_web/header_helpers_test.exs (100%) rename apps/{fz_http => web}/test/fz_http_web/html_authentication_test.exs (100%) rename apps/{fz_http => web}/test/fz_http_web/layout_view_test.exs (100%) rename apps/{fz_http => web}/test/fz_http_web/live/connectivity_check_live/index_test.exs (100%) rename apps/{fz_http => web}/test/fz_http_web/live/device_live/admin/index_test.exs (100%) rename apps/{fz_http => web}/test/fz_http_web/live/device_live/admin/show_test.exs (100%) rename apps/{fz_http => web}/test/fz_http_web/live/device_live/unprivileged/index_test.exs (100%) rename apps/{fz_http => web}/test/fz_http_web/live/device_live/unprivileged/show_test.exs (100%) rename apps/{fz_http => web}/test/fz_http_web/live/mfa_live/auth_test.exs (100%) rename apps/{fz_http => web}/test/fz_http_web/live/notifications_live/badge_test.exs (100%) rename apps/{fz_http => web}/test/fz_http_web/live/notifications_live/index_test.exs (100%) rename apps/{fz_http => web}/test/fz_http_web/live/rule_live/index_test.exs (100%) rename apps/{fz_http => web}/test/fz_http_web/live/setting_live/account_test.exs (100%) rename apps/{fz_http => web}/test/fz_http_web/live/setting_live/client_defaults_test.exs (100%) rename apps/{fz_http => web}/test/fz_http_web/live/setting_live/customization_test.exs (100%) rename apps/{fz_http => web}/test/fz_http_web/live/setting_live/security_test.exs (100%) rename apps/{fz_http => web}/test/fz_http_web/live/setting_live/unprivileged/account_test.exs (100%) rename apps/{fz_http => web}/test/fz_http_web/live/user_live/index_test.exs (100%) rename apps/{fz_http => web}/test/fz_http_web/live/user_live/show_test.exs (100%) rename apps/{fz_http => web}/test/fz_http_web/live/user_live/vpn_connection_component_test.exs (100%) rename apps/{fz_http => web}/test/fz_http_web/live/user_live/vpn_status_component_test.exs (100%) rename apps/{fz_http => web}/test/fz_http_web/mailer_test.exs (100%) rename apps/{fz_http => web}/test/fz_http_web/mailer_test/sample_email/test_heex.html.heex (100%) rename apps/{fz_http => web}/test/fz_http_web/mailer_test/sample_email/test_multipart.html.eex (100%) rename apps/{fz_http => web}/test/fz_http_web/mailer_test/sample_email/test_multipart.text.eex (100%) rename apps/{fz_http => web}/test/fz_http_web/plug/path_prefix_test.exs (100%) rename apps/{fz_http => web}/test/fz_http_web/user_from_auth_test.exs (100%) rename apps/{fz_http => web}/test/fz_http_web/views/error_view_test.exs (100%) rename apps/{fz_http => web}/test/fz_http_web/views/shared_view_test.exs (100%) rename apps/{fz_http => web}/test/support/acceptance_case.ex (100%) rename apps/{fz_http => web}/test/support/acceptance_case/auth.ex (100%) rename apps/{fz_http => web}/test/support/acceptance_case/simple_saml.ex (100%) rename apps/{fz_http => web}/test/support/acceptance_case/vault.ex (100%) rename apps/{fz_http => web}/test/support/api_case.ex (100%) rename apps/{fz_http => web}/test/support/case_template.ex (100%) rename apps/{fz_http => web}/test/support/channel_case.ex (100%) rename apps/{fz_http => web}/test/support/conn_case.ex (100%) rename apps/{fz_http => web}/test/support/data_case.ex (100%) rename apps/{fz_http => web}/test/support/docs_generator.ex (100%) rename apps/{fz_http => web}/test/support/fixtures/api_tokens_fixtures.ex (100%) rename apps/{fz_http => web}/test/support/fixtures/config_fixtures.ex (100%) rename apps/{fz_http => web}/test/support/fixtures/connectivity_checks_fixtures.ex (100%) rename apps/{fz_http => web}/test/support/fixtures/devices_fixtures.ex (100%) rename apps/{fz_http => web}/test/support/fixtures/mfa_fixtures.ex (100%) rename apps/{fz_http => web}/test/support/fixtures/notifications_fixtures.ex (100%) rename apps/{fz_http => web}/test/support/fixtures/rules_fixtures.ex (100%) rename apps/{fz_http => web}/test/support/fixtures/subject_fixtures.ex (100%) rename apps/{fz_http => web}/test/support/fixtures/users_fixtures.ex (100%) rename apps/{fz_http => web}/test/support/mailer_case.ex (100%) rename apps/{fz_http => web}/test/support/mailer_test_adapter.ex (100%) rename apps/{fz_http => web}/test/support/test_helpers.ex (100%) rename apps/{fz_http => web}/test/test_helper.exs (100%) delete mode 100644 asyncapi.yml delete mode 100644 omnibus/.gitignore delete mode 100644 omnibus/.kitchen.yml delete mode 100644 omnibus/Berksfile delete mode 100644 omnibus/Gemfile delete mode 100644 omnibus/Gemfile.lock delete mode 100644 omnibus/README.md delete mode 100644 omnibus/config/patches/bzip2/aix_makefile.patch delete mode 100644 omnibus/config/patches/bzip2/makefile_no_bins.patch delete mode 100644 omnibus/config/patches/bzip2/makefile_take_env_vars.patch delete mode 100644 omnibus/config/patches/bzip2/soname_install_dir.patch delete mode 100644 omnibus/config/patches/chef-bin/disable_license_enforce.patch delete mode 100644 omnibus/config/patches/erlang/epmd-require-explicitly-adding-loopback-address.patch delete mode 100644 omnibus/config/patches/libedit/freebsd-vi-fix.patch delete mode 100644 omnibus/config/patches/libedit/openbsd-weak-alias-fix.patch delete mode 100644 omnibus/config/patches/libffi/libffi-3.2.1-disable-multi-os-directory.patch delete mode 100644 omnibus/config/patches/libffi/libffi-3.3-arm64.patch delete mode 100644 omnibus/config/patches/m4/m4-1.4.18-glibc-change-work-around.patch delete mode 100644 omnibus/config/patches/ncurses/ncurses-5.9-gcc-5.patch delete mode 100644 omnibus/config/patches/ncurses/ncurses-5.9-solaris-xopen_source_extended-detection.patch delete mode 100644 omnibus/config/patches/ncurses/ncurses-clang.patch delete mode 100644 omnibus/config/patches/ncurses/patch-aa delete mode 100644 omnibus/config/patches/ncurses/patch-ab delete mode 100644 omnibus/config/patches/ncurses/patch-ac delete mode 100644 omnibus/config/patches/ncurses/patch-ad delete mode 100644 omnibus/config/patches/ncurses/patch-cxx_cursesf.h delete mode 100644 omnibus/config/patches/ncurses/patch-cxx_cursesm.h delete mode 100644 omnibus/config/patches/ncurses/patch-ncurses_tinfo_lib__baudrate.c delete mode 100644 omnibus/config/patches/omnibus-ctl/skip-license-acceptance.patch delete mode 100644 omnibus/config/patches/openssl/openssl-1.0.1f-do-not-build-docs.patch delete mode 100644 omnibus/config/patches/openssl/openssl-1.0.1j-windows-relocate-dll.patch delete mode 100644 omnibus/config/patches/openssl/openssl-1.0.1q-fix-compiler-flags-table-for-msys.patch delete mode 100644 omnibus/config/patches/openssl/openssl-1.0.2x-darwin-arm64.patch delete mode 100644 omnibus/config/patches/openssl/openssl-1.1.0f-do-not-install-docs.patch delete mode 100644 omnibus/config/patches/perl/perl-5.18.1-remove_lnsl.patch delete mode 100644 omnibus/config/patches/perl/perl-5.22.1-remove_lnsl.patch delete mode 100644 omnibus/config/patches/perl/perl-5.30.0-remove_lnsl.patch delete mode 100644 omnibus/config/patches/perl/perl-5.32.1-remove_lnsl.patch delete mode 100644 omnibus/config/patches/perl/perl-5.34.0-remove_lnsl.patch delete mode 100644 omnibus/config/patches/pkg-config/openbsd-charset.patch delete mode 100644 omnibus/config/patches/postgresql/no_docs.patch delete mode 100644 omnibus/config/patches/python/disable_modules.patch delete mode 100644 omnibus/config/patches/readline/8.1.patch delete mode 100644 omnibus/config/patches/ruby/patch-configure delete mode 100644 omnibus/config/patches/ruby/ruby-aix-atomic.patch delete mode 100644 omnibus/config/patches/ruby/ruby-aix-configure.patch delete mode 100644 omnibus/config/patches/ruby/ruby-aix-vm-core.patch delete mode 100644 omnibus/config/patches/ruby/ruby-disable-copy-file-range.patch delete mode 100644 omnibus/config/patches/ruby/ruby-fix-reserve-stack-segfault.patch delete mode 100644 omnibus/config/patches/ruby/ruby-freebsd-9-zlib.patch delete mode 100644 omnibus/config/patches/ruby/ruby-mkmf.patch delete mode 100644 omnibus/config/patches/ruby/ruby-no-stack-protector.patch delete mode 100644 omnibus/config/patches/ruby/ruby-openssl-1.0.1c.patch delete mode 100644 omnibus/config/patches/ruby/ruby-solaris-linux-socket-compat.patch delete mode 100644 omnibus/config/patches/ruby/ruby-sparc-1.9.3-c99.patch delete mode 100644 omnibus/config/patches/ruby/ruby_aix_1_9_3_448_ssl_EAGAIN.patch delete mode 100644 omnibus/config/patches/ruby/ruby_aix_2_1_3_ssl_EAGAIN.patch delete mode 100644 omnibus/config/patches/ruby/ruby_aix_openssl.patch delete mode 100644 omnibus/config/patches/ruby/rvm-cflags.patch delete mode 100644 omnibus/config/patches/ruby/thread-memory-allocations-2.7.patch delete mode 100644 omnibus/config/patches/rubygems/license/add-license-file.patch delete mode 100644 omnibus/config/patches/runit/log-status.patch delete mode 100644 omnibus/config/patches/zlib/zlib-windows-relocate.patch delete mode 100644 omnibus/config/projects/firezone.rb delete mode 100644 omnibus/config/software/acme.rb delete mode 100644 omnibus/config/software/autoconf.rb delete mode 100644 omnibus/config/software/automake.rb delete mode 100644 omnibus/config/software/bison.rb delete mode 100644 omnibus/config/software/bzip2.rb delete mode 100644 omnibus/config/software/cacerts.rb delete mode 100644 omnibus/config/software/config_guess.rb delete mode 100644 omnibus/config/software/elixir.rb delete mode 100644 omnibus/config/software/erlang.rb delete mode 100644 omnibus/config/software/firezone-cookbooks.rb delete mode 100644 omnibus/config/software/firezone-ctl.rb delete mode 100644 omnibus/config/software/firezone-scripts.rb delete mode 100644 omnibus/config/software/firezone.rb delete mode 100644 omnibus/config/software/flex.rb delete mode 100644 omnibus/config/software/gawk.rb delete mode 100644 omnibus/config/software/gettext.rb delete mode 100644 omnibus/config/software/gmp.rb delete mode 100644 omnibus/config/software/icu.rb delete mode 100644 omnibus/config/software/libedit.rb delete mode 100644 omnibus/config/software/libffi.rb delete mode 100644 omnibus/config/software/libiconv.rb delete mode 100644 omnibus/config/software/liblzma.rb delete mode 100644 omnibus/config/software/libmnl.rb delete mode 100644 omnibus/config/software/libnftnl.rb delete mode 100644 omnibus/config/software/libossp-uuid.rb delete mode 100644 omnibus/config/software/libtool.rb delete mode 100644 omnibus/config/software/libxml2.rb delete mode 100644 omnibus/config/software/libyaml.rb delete mode 100644 omnibus/config/software/linenoise.rb delete mode 100644 omnibus/config/software/m4.rb delete mode 100644 omnibus/config/software/ncurses.rb delete mode 100644 omnibus/config/software/nftables.rb delete mode 100644 omnibus/config/software/nginx.rb delete mode 100644 omnibus/config/software/omnibus-ctl.rb delete mode 100644 omnibus/config/software/openssl.rb delete mode 100644 omnibus/config/software/pcre.rb delete mode 100644 omnibus/config/software/perl-thread-queue.rb delete mode 100644 omnibus/config/software/perl.rb delete mode 100644 omnibus/config/software/pkg-config.rb delete mode 100644 omnibus/config/software/postgresql.rb delete mode 100644 omnibus/config/software/readline.rb delete mode 100644 omnibus/config/software/ruby.rb delete mode 100644 omnibus/config/software/rubygems.rb delete mode 100644 omnibus/config/software/runit.rb delete mode 100644 omnibus/config/software/zlib.rb delete mode 100644 omnibus/config/templates/firezone-ctl/firezone-ctl.erb delete mode 100644 omnibus/config/templates/runit/runsvdir-start.erb delete mode 100644 omnibus/cookbooks/firezone/.delivery/project.toml delete mode 100644 omnibus/cookbooks/firezone/.gitignore delete mode 100644 omnibus/cookbooks/firezone/Berksfile delete mode 100644 omnibus/cookbooks/firezone/CHANGELOG.md delete mode 100644 omnibus/cookbooks/firezone/Gemfile delete mode 100644 omnibus/cookbooks/firezone/LICENSE delete mode 100644 omnibus/cookbooks/firezone/Policyfile.rb delete mode 100644 omnibus/cookbooks/firezone/README.md delete mode 100644 omnibus/cookbooks/firezone/attributes/default.rb delete mode 100644 omnibus/cookbooks/firezone/chefignore delete mode 100644 omnibus/cookbooks/firezone/files/default/ctl-commands/create_admin.rb delete mode 100644 omnibus/cookbooks/firezone/files/default/ctl-commands/force_renewal.rb delete mode 100644 omnibus/cookbooks/firezone/files/default/ctl-commands/reconfigure.rb delete mode 100644 omnibus/cookbooks/firezone/files/default/ctl-commands/reset_network.rb delete mode 100644 omnibus/cookbooks/firezone/files/default/ctl-commands/stop_renewal.rb delete mode 100644 omnibus/cookbooks/firezone/files/default/ctl-commands/teardown.rb delete mode 100644 omnibus/cookbooks/firezone/files/default/ctl-commands/version.rb delete mode 100644 omnibus/cookbooks/firezone/kitchen.yml delete mode 100644 omnibus/cookbooks/firezone/libraries/config.rb delete mode 100644 omnibus/cookbooks/firezone/metadata.rb delete mode 100644 omnibus/cookbooks/firezone/recipes/acme.rb delete mode 100644 omnibus/cookbooks/firezone/recipes/app.rb delete mode 100644 omnibus/cookbooks/firezone/recipes/config.rb delete mode 100644 omnibus/cookbooks/firezone/recipes/create_admin.rb delete mode 100644 omnibus/cookbooks/firezone/recipes/database.rb delete mode 100644 omnibus/cookbooks/firezone/recipes/default.rb delete mode 100644 omnibus/cookbooks/firezone/recipes/force_renewal.rb delete mode 100644 omnibus/cookbooks/firezone/recipes/log_management.rb delete mode 100644 omnibus/cookbooks/firezone/recipes/network.rb delete mode 100644 omnibus/cookbooks/firezone/recipes/nginx.rb delete mode 100644 omnibus/cookbooks/firezone/recipes/phoenix.rb delete mode 100644 omnibus/cookbooks/firezone/recipes/postgresql.rb delete mode 100644 omnibus/cookbooks/firezone/recipes/setcap.rb delete mode 100644 omnibus/cookbooks/firezone/recipes/show_config.rb delete mode 100644 omnibus/cookbooks/firezone/recipes/ssl.rb delete mode 100644 omnibus/cookbooks/firezone/recipes/stop_renewal.rb delete mode 100644 omnibus/cookbooks/firezone/recipes/teardown.rb delete mode 100644 omnibus/cookbooks/firezone/recipes/telemetry.rb delete mode 100644 omnibus/cookbooks/firezone/recipes/wireguard.rb delete mode 100644 omnibus/cookbooks/firezone/templates/firezone.rb.erb delete mode 100644 omnibus/cookbooks/firezone/templates/logrotate-rule.erb delete mode 100644 omnibus/cookbooks/firezone/templates/logrotate.conf.erb delete mode 100644 omnibus/cookbooks/firezone/templates/logrotate.cron.erb delete mode 100644 omnibus/cookbooks/firezone/templates/nginx.conf.erb delete mode 100644 omnibus/cookbooks/firezone/templates/pg_hba.conf.erb delete mode 100644 omnibus/cookbooks/firezone/templates/phoenix.nginx.conf.erb delete mode 100644 omnibus/cookbooks/firezone/templates/postgresql.conf.erb delete mode 100644 omnibus/cookbooks/firezone/templates/redirect.conf.erb delete mode 100644 omnibus/cookbooks/firezone/templates/ssl-signing.conf.erb delete mode 100644 omnibus/cookbooks/firezone/templates/sv-nginx-log-run.erb delete mode 100644 omnibus/cookbooks/firezone/templates/sv-nginx-run.erb delete mode 100644 omnibus/cookbooks/firezone/templates/sv-phoenix-finish.erb delete mode 100644 omnibus/cookbooks/firezone/templates/sv-phoenix-log-run.erb delete mode 100644 omnibus/cookbooks/firezone/templates/sv-phoenix-run.erb delete mode 100644 omnibus/cookbooks/firezone/templates/sv-phoenix-t.erb delete mode 100644 omnibus/cookbooks/firezone/templates/sv-postgresql-log-run.erb delete mode 100644 omnibus/cookbooks/firezone/templates/sv-postgresql-run.erb delete mode 100644 omnibus/cookbooks/firezone/templates/sv-postgresql-t.erb delete mode 100644 omnibus/cookbooks/firezone/templates/sv-wireguard-log-run.erb delete mode 100644 omnibus/cookbooks/firezone/templates/sv-wireguard-run.erb delete mode 100644 omnibus/cookbooks/firezone/test/integration/default/default_test.rb delete mode 100755 omnibus/files/firezone-scripts/symlink_ctl_cmds delete mode 100755 omnibus/files/firezone-scripts/wireguard delete mode 100644 omnibus/omnibus.rb delete mode 100755 omnibus/package-scripts/firezone/postinst delete mode 100755 omnibus/package-scripts/firezone/postrm delete mode 100755 omnibus/package-scripts/firezone/preinst delete mode 100755 omnibus/package-scripts/firezone/prerm delete mode 100644 www/docs/deploy/omnibus/README.mdx delete mode 100644 www/docs/deploy/omnibus/supported-platforms.mdx diff --git a/.codespellrc b/.codespellrc index 160e06e11..7a2c37253 100644 --- a/.codespellrc +++ b/.codespellrc @@ -1,3 +1,3 @@ [codespell] -skip = ./www/docs/reference/api/*.mdx,./erl_crash.dump,./apps/fz_http/erl_crash.dump,./cover,./vendor,./omnibus,*.json,yarn.lock,seeds.exs,./**/node_modules,./deps,./priv/static,./priv/plts,./**/priv/static,./.git,./www/build,./_build +skip = ./www/docs/reference/api/*.mdx,./erl_crash.dump,./apps/*/erl_crash.dump,./cover,./vendor,*.json,yarn.lock,seeds.exs,./**/node_modules,./deps,./priv/static,./priv/plts,./**/priv/static,./.git,./www/build,./_build ignore-words-list = crate,keypair,keypairs,iif,statics,wee,anull diff --git a/.dockerignore b/.dockerignore index 033d76adb..14996481d 100644 --- a/.dockerignore +++ b/.dockerignore @@ -1,6 +1,6 @@ -apps/fz_http/assets/node_modules -apps/fz_http/priv/static/dist -apps/fz_http/priv/cert +apps/web/assets/node_modules +apps/web/priv/static/dist +apps/web/priv/cert _build **/cover docs diff --git a/.github/workflows/omnibus_build.yml b/.github/workflows/omnibus_build.yml deleted file mode 100644 index ea054de27..000000000 --- a/.github/workflows/omnibus_build.yml +++ /dev/null @@ -1,166 +0,0 @@ -# We're running on a self-hosted runner, so only allow one workflow to run at a -# time. -concurrency: build - -name: Omnibus Build -on: - push: - branches: - - master - - "build/**" - -jobs: - draft-release: - runs-on: ubuntu-latest - outputs: - tag_name: ${{ steps.release_drafter.outputs.tag_name }} - steps: - - uses: release-drafter/release-drafter@v5 - id: release_drafter - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - - build-package-test: - # Doesn't really need, but don't run this stage when iterating over website - needs: draft-release - env: - TELEMETRY_ENABLED: "false" - TERMINFO: /usr/lib/terminfo - runs-on: ${{ matrix.platform }} - strategy: - # Failing fast breaks the Omnibus build cache because the job is - # interrupted abruptly, leaving behind index.lock files. - fail-fast: false - matrix: - platform: - # ARM-based - - amazonlinux2-arm64 - - centos9-arm64 - - debian10-arm64 - - debian11-arm64 - - fedora33-arm64 - - fedora34-arm64 - - fedora35-arm64 - - ubuntu1804-arm64 - - ubuntu2004-arm64 - - # x64-based - - amazonlinux2-x64 - - centos7-x64 - - centos8-x64 - - centos9-x64 - - debian10-x64 - - debian11-x64 - - fedora33-x64 - - fedora34-x64 - - fedora35-x64 - - ubuntu1804-x64 - - ubuntu2004-x64 - - opensuse15-x64 - steps: - - run: cat /sys/module/wireguard/version - - uses: actions/checkout@v3 - - name: Build - env: - GIT_SHA: ${{ github.sha }} - VERSION: ${{ needs.draft-release.outputs.tag_name }} - run: | - echo "removing lock file in case last run sucked" - sudo rm -f /opt/runner/omnibus-local/cache/git_cache/opt/firezone/index.lock - - # Load newer git on CentOS 7 - if test -f /opt/rh/rh-git227/enable; then - . /opt/rh/rh-git227/enable - fi - - . $HOME/.asdf/asdf.sh - asdf update - asdf plugin-add ruby || asdf plugin-update ruby - asdf install ruby - - # Needed for building assets later on - asdf plugin-add nodejs || asdf plugin-update nodejs - asdf install nodejs - npm install --global yarn - - # CentOS 7 has path issues when this runs and doesn't have the - # devtools loaded - if test -f /opt/rh/devtoolset-9/enable; then - . /opt/rh/devtoolset-9/enable - fi - - gem install bundler - cd omnibus - bundle install --binstubs - sudo mkdir -p /opt/firezone - sudo chown -R $USER /opt/firezone - bin/omnibus build firezone - - uses: actions/upload-artifact@v3 - with: - name: firezone-${{ matrix.platform }} - path: | - omnibus/pkg/firezone*.deb - omnibus/pkg/firezone*.rpm - - name: Functional Test - run: | - .ci/functional_test.sh - - name: Cleanup - if: always() - run: | - sudo scripts/omnibus-uninstall.sh - sudo rm -rf /tmp/firezone* - rm -rf omnibus/pkg/* - - # Publish packages to the drafted release on merges to master so we can - # manually test them if needed. Then we can just publish the drafted release - # and we're good to go. - publish: - if: startsWith(github.ref, 'refs/heads/master') - needs: - - build-package-test - - draft-release - runs-on: ubuntu-20.04 - strategy: - matrix: - platform: - # ARM-based - - amazonlinux2-arm64 - - centos9-arm64 - - debian10-arm64 - - debian11-arm64 - - fedora33-arm64 - - fedora34-arm64 - - fedora35-arm64 - - ubuntu1804-arm64 - - ubuntu2004-arm64 - - # x64-based - - amazonlinux2-x64 - - centos7-x64 - - centos8-x64 - - centos9-x64 - - debian10-x64 - - debian11-x64 - - fedora33-x64 - - fedora34-x64 - - fedora35-x64 - - ubuntu1804-x64 - - ubuntu2004-x64 - - opensuse15-x64 - steps: - - uses: actions/download-artifact@v3 - with: - name: firezone-${{ matrix.platform }} - path: ./ - - name: Rename artifact file to tag - run: | - mv ./firezone*.rpm firezone_${{ needs.draft-release.outputs.tag_name }}-${{ matrix.platform }}.rpm || true - mv ./firezone*.deb firezone_${{ needs.draft-release.outputs.tag_name }}-${{ matrix.platform }}.deb || true - - name: Release - uses: softprops/action-gh-release@v1 - with: - tag_name: ${{ needs.draft-release.outputs.tag_name }} - draft: true - files: | - ./firezone*.rpm - ./firezone*.deb diff --git a/.github/workflows/omnibus_publish.yml b/.github/workflows/omnibus_publish.yml deleted file mode 100644 index 7e16c495d..000000000 --- a/.github/workflows/omnibus_publish.yml +++ /dev/null @@ -1,183 +0,0 @@ -name: Publish to Cloudsmith - -on: - release: - types: [published] - -jobs: - publish: - runs-on: ubuntu-20.04 - strategy: - fail-fast: false - matrix: - include: - # ARM-based - - platform: amazonlinux2-arm64 - distro: amzn - release: '2' - - platform: centos9-arm64 - distro: el - release: '9' - - platform: debian10-arm64 - distro: debian - release: buster - - platform: debian11-arm64 - distro: debian - release: bullseye - - platform: debian10-arm64 - distro: raspbian - release: buster - - platform: debian11-arm64 - distro: raspbian - release: bullseye - - platform: fedora33-arm64 - distro: fedora - release: '33' - - platform: fedora34-arm64 - distro: fedora - release: '34' - - platform: fedora35-arm64 - distro: fedora - release: '35' - - platform: fedora35-arm64 - distro: fedora - release: '36' - - platform: ubuntu1804-arm64 - distro: ubuntu - release: bionic - - platform: ubuntu2004-arm64 - distro: ubuntu - release: focal - - platform: ubuntu2004-arm64 - distro: ubuntu - release: hirsute - - platform: ubuntu2004-arm64 - distro: ubuntu - release: jammy - - # x64-based - - platform: amazonlinux2-x64 - distro: amzn - release: '2' - - platform: centos7-x64 - distro: el - release: '7' - - platform: centos8-x64 - distro: el - release: '8' - - platform: centos9-x64 - distro: el - release: '9' - - platform: centos8-x64 - distro: rocky - release: '8.3' - - platform: centos8-x64 - distro: rocky - release: '8.4' - - platform: centos8-x64 - distro: rocky - release: '8.5' - - platform: centos8-x64 - distro: rocky - release: '8.6' - - platform: centos8-x64 - distro: almalinux - release: '8.3' - - platform: centos8-x64 - distro: almalinux - release: '8.4' - - platform: centos8-x64 - distro: almalinux - release: '8.5' - - platform: debian10-x64 - distro: debian - release: buster - - platform: debian11-x64 - distro: debian - release: bullseye - - platform: fedora33-x64 - distro: fedora - release: '33' - - platform: fedora34-x64 - distro: fedora - release: '34' - - platform: fedora35-x64 - distro: fedora - release: '35' - - platform: fedora35-x64 - distro: fedora - release: '36' - - platform: ubuntu1804-x64 - distro: ubuntu - release: bionic - - platform: ubuntu2004-x64 - distro: ubuntu - release: focal - - platform: ubuntu2004-x64 - distro: ubuntu - release: hirsute - - platform: ubuntu2004-x64 - distro: ubuntu - release: jammy - - platform: opensuse15-x64 - distro: opensuse - release: '15.1' - - platform: opensuse15-x64 - distro: opensuse - release: '15.2' - - platform: opensuse15-x64 - distro: opensuse - release: '15.3' - steps: - - name: Download artifact - uses: dawidd6/action-download-artifact@v2 - with: - commit: ${{ github.sha }} - workflow: omnibus_build.yml - workflow_conclusion: success - name: firezone-${{ matrix.platform }} - - - name: Rename artifact file to tag - run: | - mv ./firezone*.rpm firezone_${{ github.ref_name }}-${{ matrix.platform }}.rpm || true - mv ./firezone*.deb firezone_${{ github.ref_name }}-${{ matrix.platform }}.deb || true - - - name: Check DEB - uses: andstor/file-existence-action@v2 - id: check_deb - with: - files: firezone_${{ github.ref_name }}-${{ matrix.platform }}.deb - - - name: Check RPM - uses: andstor/file-existence-action@v2 - id: check_rpm - with: - files: firezone_${{ github.ref_name }}-${{ matrix.platform }}.rpm - - - name: Pubslih RPM - uses: cloudsmith-io/action@master - if: steps.check_rpm.outputs.files_exists == 'true' - with: - api-key: ${{ secrets.CLOUDSMITH_API_KEY }} - command: 'push' - format: 'rpm' - owner: 'firezone' - repo: 'firezone' - distro: ${{ matrix.distro }} - release: ${{ matrix.release }} - republish: 'true' - file: firezone_${{ github.ref_name }}-${{ matrix.platform }}.rpm - - - name: Publish DEB - uses: cloudsmith-io/action@master - if: steps.check_deb.outputs.files_exists == 'true' - with: - api-key: ${{ secrets.CLOUDSMITH_API_KEY }} - command: 'push' - format: 'deb' - owner: 'firezone' - repo: 'firezone' - distro: ${{ matrix.distro }} - release: ${{ matrix.release }} - republish: 'true' - file: firezone_${{ github.ref_name }}-${{ matrix.platform }}.deb diff --git a/.github/workflows/static_analysis.yml b/.github/workflows/static_analysis.yml index df52b8b6c..98e337e91 100644 --- a/.github/workflows/static_analysis.yml +++ b/.github/workflows/static_analysis.yml @@ -18,11 +18,8 @@ jobs: node-version: '16' cache: 'yarn' cache-dependency-path: | - apps/fz_http/assets/package-lock.json + apps/web/assets/package-lock.json www/yarn.lock - - uses: ruby/setup-ruby@v1 - with: - ruby-version: '2.7' - uses: actions/setup-python@v2 with: python-version: '3.9' @@ -42,13 +39,6 @@ jobs: key: ${{ github.workflow }}-${{ runner.os }}-${{ env.cache-name }}-${{ hashFiles('**/mix.lock') }} restore-keys: | ${{ github.workflow }}-${{ runner.os }}-${{ env.cache-name }}- - - uses: actions/cache@v3.0.11 - name: Setup ruby cache - with: - path: vendor/bundle - key: ${{ runner.os }}-gems-${{ hashFiles('**/Gemfile.lock') }} - restore-keys: | - ${{ runner.os }}-gems- - uses: actions/cache@v3.0.11 name: Setup Python cache with: @@ -58,10 +48,6 @@ jobs: ${{ runner.os }}-pip- - name: Install Elixir Dependencies run: mix deps.get --only $MIX_ENV - - name: Install Ruby Dependencies - run: | - bundle config path vendor/bundle - bundle install --jobs 4 --retry 3 - name: Install Python Dependencies run: | pip install -r requirements.txt diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 4f70e39c2..fd88153d1 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -167,7 +167,6 @@ jobs: MIX_ENV: dev POSTGRES_HOST: localhost GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - FZ_VPN_WG_ADAPTER: FzVpn.Interface.WGAdapter.Sandbox services: postgres: image: postgres:15 @@ -223,7 +222,7 @@ jobs: with: branch: master name: db-dump - path: apps/fz_http/priv/repo/ + path: apps/web/priv/repo/ search_artifacts: true workflow_conclusion: completed if_no_artifact_found: fail @@ -246,7 +245,7 @@ jobs: run: | pg_dump firezone_dev \ -U postgres -h localhost \ - --file apps/fz_http/priv/repo/structure.sql \ + --file apps/web/priv/repo/structure.sql \ --no-acl \ --no-owner - name: Upload master branch DB dump @@ -254,7 +253,7 @@ jobs: uses: actions/upload-artifact@v3 with: name: db-dump - path: apps/fz_http/priv/repo/structure.sql + path: apps/web/priv/repo/structure.sql - name: Run Seed run: mix ecto.seed acceptance-test: @@ -338,14 +337,14 @@ jobs: env: cache-name: cache-yarn-build-${{ env.MIX_ENV }} with: - path: apps/fz_http/assets/node_modules + path: apps/web/assets/node_modules key: ${{ runner.os }}-${{ env.cache-name }}-${{ hashFiles('**/yarn.lock') }} - uses: actions/cache@v3 name: Assets Cache env: cache-name: cache-assets-build-${{ env.MIX_ENV }} with: - path: apps/fz_http/priv/static/dist + path: apps/web/priv/static/dist key: ${{ runner.os }}-${{ env.cache-name }}-${{ hashFiles('**/yarn.lock') }} - name: Install Dependencies run: mix deps.get --only $MIX_ENV @@ -355,11 +354,11 @@ jobs: run: mix compile - name: Install Node Dependencies run: | - cd apps/fz_http/assets + cd apps/web/assets yarn install --frozen-lockfile - name: Build Assets run: | - cd apps/fz_http/assets + cd apps/web/assets yarn deploy - name: Setup Database run: | @@ -384,7 +383,7 @@ jobs: uses: actions/upload-artifact@v3 with: name: screenshots - path: apps/fz_http/screenshots + path: apps/web/screenshots - name: Test Report uses: dorny/test-reporter@v1 if: ${{ github.event.pull_request.head.repo.full_name == github.repository && (success() || failure()) }} diff --git a/.gitignore b/.gitignore index 0ad96f9b0..237681167 100644 --- a/.gitignore +++ b/.gitignore @@ -61,11 +61,13 @@ npm-debug.log /*.rpm # Test screenshots -apps/fz_http/screenshots +apps/*/screenshots # WG configs generated in acceptance tests *.conf # Auto generated private key -apps/fz_http/priv/wg_dev_private_key -apps/fz_http/priv/static/uploads +apps/web/priv/wg_dev_private_key + +# Uploads +apps/web/priv/static/uploads diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index c684de9fe..9249816f1 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -29,12 +29,6 @@ repos: entry: codespell language: system pass_filenames: false - - id: rubocop - name: 'ruby: rubocop' - entry: bundle exec rubocop - language: system - pass_filenames: false - files: \.rb$ - id: markdownlint name: 'nodejs: markdownlint' entry: ./docs/node_modules/markdownlint-cli/markdownlint.js @@ -52,9 +46,7 @@ repos: - id: check-yaml - id: check-merge-conflict - id: end-of-file-fixer - exclude: "^omnibus/config/patches/" - id: trailing-whitespace - exclude: "^omnibus/config/patches/" - id: check-merge-conflict - id: no-commit-to-branch args: diff --git a/.rubocop.yml b/.rubocop.yml deleted file mode 100644 index 2a553250e..000000000 --- a/.rubocop.yml +++ /dev/null @@ -1,6 +0,0 @@ -AllCops: - TargetRubyVersion: 2.7 - Exclude: - - "vendor/**/*" - - "apps/fz_http/assets/node_modules/**/*" - - "omnibus/cookbooks/firezone/attributes/default.rb" diff --git a/.tool-versions b/.tool-versions index ef7e9f406..665cb663a 100644 --- a/.tool-versions +++ b/.tool-versions @@ -5,5 +5,4 @@ elixir 1.14.3-otp-25 erlang 25.2.1 # Used for static analysis -ruby 2.7.6 python 3.9.13 diff --git a/Dockerfile.dev b/Dockerfile.dev index 41eba82e6..91e49b86e 100644 --- a/Dockerfile.dev +++ b/Dockerfile.dev @@ -37,23 +37,23 @@ ENV DATABASE_PASSWORD=$DATABASE_PASSWORD RUN mix local.hex --force && mix local.rebar --force -COPY apps/fz_http/mix.exs /var/app/apps/fz_http/mix.exs -COPY apps/fz_vpn/mix.exs /var/app/apps/fz_vpn/mix.exs -COPY apps/fz_wall/mix.exs /var/app/apps/fz_wall/mix.exs +COPY apps/domain/mix.exs /var/app/apps/web/mix.exs +COPY apps/web/mix.exs /var/app/apps/web/mix.exs +COPY apps/api/mix.exs /var/app/apps/api/mix.exs COPY mix.exs /var/app/mix.exs COPY mix.lock /var/app/mix.lock RUN mix do deps.get, deps.compile, compile # Copy more granular, dependency management files first to prevent # busting the Docker build cache unnecessarily -COPY apps/fz_http/assets/package.json /var/app/apps/fz_http/assets/package.json -COPY apps/fz_http/assets/local_modules /var/app/apps/fz_http/assets/local_modules -COPY apps/fz_http/assets/yarn.lock /var/app/apps/fz_http/assets/yarn.lock -RUN cd apps/fz_http/assets && yarn install +COPY apps/web/assets/package.json /var/app/apps/web/assets/package.json +COPY apps/web/assets/local_modules /var/app/apps/web/assets/local_modules +COPY apps/web/assets/yarn.lock /var/app/apps/web/assets/yarn.lock +RUN cd apps/web/assets && yarn install COPY config /var/app/config COPY apps /var/app/apps -RUN cd apps/fz_http && mix phx.gen.cert +RUN cd apps/web && mix phx.gen.cert COPY scripts/dev_start.sh /var/app/dev_start.sh diff --git a/Dockerfile.prod b/Dockerfile.prod index 8ef1aec52..7abd6bf29 100644 --- a/Dockerfile.prod +++ b/Dockerfile.prod @@ -22,9 +22,9 @@ ENV MIX_ENV="prod" # install mix dependencies COPY mix.exs mix.lock ./ -COPY apps/fz_http/mix.exs ./apps/fz_http/mix.exs -COPY apps/fz_vpn/mix.exs ./apps/fz_vpn/mix.exs -COPY apps/fz_wall/mix.exs ./apps/fz_wall/mix.exs +COPY apps/domain/mix.exs ./apps/domain/mix.exs +COPY apps/web/mix.exs ./apps/web/mix.exs +COPY apps/api/mix.exs ./apps/api/mix.exs RUN mix deps.get --only $MIX_ENV RUN mkdir config @@ -38,12 +38,12 @@ RUN mix deps.compile COPY priv priv COPY apps apps -# mix phx.digest triggers fz_http compilation, need version to be set here +# mix phx.digest triggers web compilation, need version to be set here ARG VERSION=0.0.0-docker ENV VERSION=$VERSION # compile assets -RUN cd apps/fz_http/assets \ +RUN cd apps/web/assets \ && yarn install --frozen-lockfile \ && yarn deploy \ && cd .. \ diff --git a/Gemfile b/Gemfile deleted file mode 100644 index 11d1436b6..000000000 --- a/Gemfile +++ /dev/null @@ -1,5 +0,0 @@ -# frozen_string_literal: true - -source 'https://rubygems.org' - -gem 'rubocop' diff --git a/Gemfile.lock b/Gemfile.lock deleted file mode 100644 index 70f1c47ea..000000000 --- a/Gemfile.lock +++ /dev/null @@ -1,35 +0,0 @@ -GEM - remote: https://rubygems.org/ - specs: - ast (2.4.2) - json (2.6.3) - parallel (1.22.1) - parser (3.2.1.1) - ast (~> 2.4.1) - rainbow (3.1.1) - regexp_parser (2.7.0) - rexml (3.2.5) - rubocop (1.48.1) - json (~> 2.3) - parallel (~> 1.10) - parser (>= 3.2.0.0) - rainbow (>= 2.2.2, < 4.0) - regexp_parser (>= 1.8, < 3.0) - rexml (>= 3.2.5, < 4.0) - rubocop-ast (>= 1.26.0, < 2.0) - ruby-progressbar (~> 1.7) - unicode-display_width (>= 2.4.0, < 3.0) - rubocop-ast (1.27.0) - parser (>= 3.2.1.0) - ruby-progressbar (1.13.0) - unicode-display_width (2.4.2) - -PLATFORMS - arm64-darwin-21 - x86_64-linux - -DEPENDENCIES - rubocop - -BUNDLED WITH - 2.3.14 diff --git a/apps/fz_http/lib/fz_http.ex b/apps/domain/fz_http.ex similarity index 100% rename from apps/fz_http/lib/fz_http.ex rename to apps/domain/fz_http.ex diff --git a/apps/fz_http/lib/fz_http/api_tokens.ex b/apps/domain/fz_http/api_tokens.ex similarity index 100% rename from apps/fz_http/lib/fz_http/api_tokens.ex rename to apps/domain/fz_http/api_tokens.ex diff --git a/apps/fz_http/lib/fz_http/api_tokens/api_token.ex b/apps/domain/fz_http/api_tokens/api_token.ex similarity index 100% rename from apps/fz_http/lib/fz_http/api_tokens/api_token.ex rename to apps/domain/fz_http/api_tokens/api_token.ex diff --git a/apps/fz_http/lib/fz_http/api_tokens/api_token/changeset.ex b/apps/domain/fz_http/api_tokens/api_token/changeset.ex similarity index 100% rename from apps/fz_http/lib/fz_http/api_tokens/api_token/changeset.ex rename to apps/domain/fz_http/api_tokens/api_token/changeset.ex diff --git a/apps/fz_http/lib/fz_http/api_tokens/api_token/query.ex b/apps/domain/fz_http/api_tokens/api_token/query.ex similarity index 100% rename from apps/fz_http/lib/fz_http/api_tokens/api_token/query.ex rename to apps/domain/fz_http/api_tokens/api_token/query.ex diff --git a/apps/fz_http/lib/fz_http/api_tokens/authorizer.ex b/apps/domain/fz_http/api_tokens/authorizer.ex similarity index 100% rename from apps/fz_http/lib/fz_http/api_tokens/authorizer.ex rename to apps/domain/fz_http/api_tokens/authorizer.ex diff --git a/apps/fz_http/lib/fz_http/application.ex b/apps/domain/fz_http/application.ex similarity index 100% rename from apps/fz_http/lib/fz_http/application.ex rename to apps/domain/fz_http/application.ex diff --git a/apps/fz_http/lib/fz_http/auth.ex b/apps/domain/fz_http/auth.ex similarity index 100% rename from apps/fz_http/lib/fz_http/auth.ex rename to apps/domain/fz_http/auth.ex diff --git a/apps/fz_http/lib/fz_http/auth/authorizer.ex b/apps/domain/fz_http/auth/authorizer.ex similarity index 100% rename from apps/fz_http/lib/fz_http/auth/authorizer.ex rename to apps/domain/fz_http/auth/authorizer.ex diff --git a/apps/fz_http/lib/fz_http/auth/context.ex b/apps/domain/fz_http/auth/context.ex similarity index 100% rename from apps/fz_http/lib/fz_http/auth/context.ex rename to apps/domain/fz_http/auth/context.ex diff --git a/apps/fz_http/lib/fz_http/auth/mfa.ex b/apps/domain/fz_http/auth/mfa.ex similarity index 100% rename from apps/fz_http/lib/fz_http/auth/mfa.ex rename to apps/domain/fz_http/auth/mfa.ex diff --git a/apps/fz_http/lib/fz_http/auth/mfa/method.ex b/apps/domain/fz_http/auth/mfa/method.ex similarity index 100% rename from apps/fz_http/lib/fz_http/auth/mfa/method.ex rename to apps/domain/fz_http/auth/mfa/method.ex diff --git a/apps/fz_http/lib/fz_http/auth/mfa/method/changeset.ex b/apps/domain/fz_http/auth/mfa/method/changeset.ex similarity index 100% rename from apps/fz_http/lib/fz_http/auth/mfa/method/changeset.ex rename to apps/domain/fz_http/auth/mfa/method/changeset.ex diff --git a/apps/fz_http/lib/fz_http/auth/mfa/method/query.ex b/apps/domain/fz_http/auth/mfa/method/query.ex similarity index 100% rename from apps/fz_http/lib/fz_http/auth/mfa/method/query.ex rename to apps/domain/fz_http/auth/mfa/method/query.ex diff --git a/apps/fz_http/lib/fz_http/auth/oidc.ex b/apps/domain/fz_http/auth/oidc.ex similarity index 100% rename from apps/fz_http/lib/fz_http/auth/oidc.ex rename to apps/domain/fz_http/auth/oidc.ex diff --git a/apps/fz_http/lib/fz_http/auth/oidc/connection.ex b/apps/domain/fz_http/auth/oidc/connection.ex similarity index 100% rename from apps/fz_http/lib/fz_http/auth/oidc/connection.ex rename to apps/domain/fz_http/auth/oidc/connection.ex diff --git a/apps/fz_http/lib/fz_http/auth/oidc/connection/changeset.ex b/apps/domain/fz_http/auth/oidc/connection/changeset.ex similarity index 100% rename from apps/fz_http/lib/fz_http/auth/oidc/connection/changeset.ex rename to apps/domain/fz_http/auth/oidc/connection/changeset.ex diff --git a/apps/fz_http/lib/fz_http/auth/oidc/connection/query.ex b/apps/domain/fz_http/auth/oidc/connection/query.ex similarity index 100% rename from apps/fz_http/lib/fz_http/auth/oidc/connection/query.ex rename to apps/domain/fz_http/auth/oidc/connection/query.ex diff --git a/apps/fz_http/lib/fz_http/auth/oidc/refresh_manager.ex b/apps/domain/fz_http/auth/oidc/refresh_manager.ex similarity index 100% rename from apps/fz_http/lib/fz_http/auth/oidc/refresh_manager.ex rename to apps/domain/fz_http/auth/oidc/refresh_manager.ex diff --git a/apps/fz_http/lib/fz_http/auth/oidc/refresher.ex b/apps/domain/fz_http/auth/oidc/refresher.ex similarity index 100% rename from apps/fz_http/lib/fz_http/auth/oidc/refresher.ex rename to apps/domain/fz_http/auth/oidc/refresher.ex diff --git a/apps/fz_http/lib/fz_http/auth/permission.ex b/apps/domain/fz_http/auth/permission.ex similarity index 100% rename from apps/fz_http/lib/fz_http/auth/permission.ex rename to apps/domain/fz_http/auth/permission.ex diff --git a/apps/fz_http/lib/fz_http/auth/role.ex b/apps/domain/fz_http/auth/role.ex similarity index 100% rename from apps/fz_http/lib/fz_http/auth/role.ex rename to apps/domain/fz_http/auth/role.ex diff --git a/apps/fz_http/lib/fz_http/auth/roles.ex b/apps/domain/fz_http/auth/roles.ex similarity index 100% rename from apps/fz_http/lib/fz_http/auth/roles.ex rename to apps/domain/fz_http/auth/roles.ex diff --git a/apps/fz_http/lib/fz_http/auth/saml/start_proxy.ex b/apps/domain/fz_http/auth/saml/start_proxy.ex similarity index 100% rename from apps/fz_http/lib/fz_http/auth/saml/start_proxy.ex rename to apps/domain/fz_http/auth/saml/start_proxy.ex diff --git a/apps/fz_http/lib/fz_http/auth/subject.ex b/apps/domain/fz_http/auth/subject.ex similarity index 100% rename from apps/fz_http/lib/fz_http/auth/subject.ex rename to apps/domain/fz_http/auth/subject.ex diff --git a/apps/fz_http/lib/fz_http/config.ex b/apps/domain/fz_http/config.ex similarity index 100% rename from apps/fz_http/lib/fz_http/config.ex rename to apps/domain/fz_http/config.ex diff --git a/apps/fz_http/lib/fz_http/config/authorizer.ex b/apps/domain/fz_http/config/authorizer.ex similarity index 100% rename from apps/fz_http/lib/fz_http/config/authorizer.ex rename to apps/domain/fz_http/config/authorizer.ex diff --git a/apps/fz_http/lib/fz_http/config/caster.ex b/apps/domain/fz_http/config/caster.ex similarity index 100% rename from apps/fz_http/lib/fz_http/config/caster.ex rename to apps/domain/fz_http/config/caster.ex diff --git a/apps/fz_http/lib/fz_http/config/configuration.ex b/apps/domain/fz_http/config/configuration.ex similarity index 100% rename from apps/fz_http/lib/fz_http/config/configuration.ex rename to apps/domain/fz_http/config/configuration.ex diff --git a/apps/fz_http/lib/fz_http/config/configuration/changeset.ex b/apps/domain/fz_http/config/configuration/changeset.ex similarity index 100% rename from apps/fz_http/lib/fz_http/config/configuration/changeset.ex rename to apps/domain/fz_http/config/configuration/changeset.ex diff --git a/apps/fz_http/lib/fz_http/config/configuration/openid_connect_provider.ex b/apps/domain/fz_http/config/configuration/openid_connect_provider.ex similarity index 100% rename from apps/fz_http/lib/fz_http/config/configuration/openid_connect_provider.ex rename to apps/domain/fz_http/config/configuration/openid_connect_provider.ex diff --git a/apps/fz_http/lib/fz_http/config/configuration/saml_identity_provider.ex b/apps/domain/fz_http/config/configuration/saml_identity_provider.ex similarity index 100% rename from apps/fz_http/lib/fz_http/config/configuration/saml_identity_provider.ex rename to apps/domain/fz_http/config/configuration/saml_identity_provider.ex diff --git a/apps/fz_http/lib/fz_http/config/definition.ex b/apps/domain/fz_http/config/definition.ex similarity index 100% rename from apps/fz_http/lib/fz_http/config/definition.ex rename to apps/domain/fz_http/config/definition.ex diff --git a/apps/fz_http/lib/fz_http/config/definitions.ex b/apps/domain/fz_http/config/definitions.ex similarity index 100% rename from apps/fz_http/lib/fz_http/config/definitions.ex rename to apps/domain/fz_http/config/definitions.ex diff --git a/apps/fz_http/lib/fz_http/config/dumper.ex b/apps/domain/fz_http/config/dumper.ex similarity index 100% rename from apps/fz_http/lib/fz_http/config/dumper.ex rename to apps/domain/fz_http/config/dumper.ex diff --git a/apps/fz_http/lib/fz_http/config/errors.ex b/apps/domain/fz_http/config/errors.ex similarity index 100% rename from apps/fz_http/lib/fz_http/config/errors.ex rename to apps/domain/fz_http/config/errors.ex diff --git a/apps/fz_http/lib/fz_http/config/fetcher.ex b/apps/domain/fz_http/config/fetcher.ex similarity index 100% rename from apps/fz_http/lib/fz_http/config/fetcher.ex rename to apps/domain/fz_http/config/fetcher.ex diff --git a/apps/fz_http/lib/fz_http/config/logo.ex b/apps/domain/fz_http/config/logo.ex similarity index 100% rename from apps/fz_http/lib/fz_http/config/logo.ex rename to apps/domain/fz_http/config/logo.ex diff --git a/apps/fz_http/lib/fz_http/config/resolver.ex b/apps/domain/fz_http/config/resolver.ex similarity index 100% rename from apps/fz_http/lib/fz_http/config/resolver.ex rename to apps/domain/fz_http/config/resolver.ex diff --git a/apps/fz_http/lib/fz_http/config/validator.ex b/apps/domain/fz_http/config/validator.ex similarity index 100% rename from apps/fz_http/lib/fz_http/config/validator.ex rename to apps/domain/fz_http/config/validator.ex diff --git a/apps/fz_http/lib/fz_http/connectivity_checks.ex b/apps/domain/fz_http/connectivity_checks.ex similarity index 100% rename from apps/fz_http/lib/fz_http/connectivity_checks.ex rename to apps/domain/fz_http/connectivity_checks.ex diff --git a/apps/fz_http/lib/fz_http/connectivity_checks/authorizer.ex b/apps/domain/fz_http/connectivity_checks/authorizer.ex similarity index 100% rename from apps/fz_http/lib/fz_http/connectivity_checks/authorizer.ex rename to apps/domain/fz_http/connectivity_checks/authorizer.ex diff --git a/apps/fz_http/lib/fz_http/connectivity_checks/connectivity_check.ex b/apps/domain/fz_http/connectivity_checks/connectivity_check.ex similarity index 100% rename from apps/fz_http/lib/fz_http/connectivity_checks/connectivity_check.ex rename to apps/domain/fz_http/connectivity_checks/connectivity_check.ex diff --git a/apps/fz_http/lib/fz_http/connectivity_checks/connectivity_check/changeset.ex b/apps/domain/fz_http/connectivity_checks/connectivity_check/changeset.ex similarity index 100% rename from apps/fz_http/lib/fz_http/connectivity_checks/connectivity_check/changeset.ex rename to apps/domain/fz_http/connectivity_checks/connectivity_check/changeset.ex diff --git a/apps/fz_http/lib/fz_http/connectivity_checks/connectivity_check/query.ex b/apps/domain/fz_http/connectivity_checks/connectivity_check/query.ex similarity index 100% rename from apps/fz_http/lib/fz_http/connectivity_checks/connectivity_check/query.ex rename to apps/domain/fz_http/connectivity_checks/connectivity_check/query.ex diff --git a/apps/fz_http/lib/fz_http/connectivity_checks/poller.ex b/apps/domain/fz_http/connectivity_checks/poller.ex similarity index 100% rename from apps/fz_http/lib/fz_http/connectivity_checks/poller.ex rename to apps/domain/fz_http/connectivity_checks/poller.ex diff --git a/apps/fz_http/lib/fz_http/crypto.ex b/apps/domain/fz_http/crypto.ex similarity index 100% rename from apps/fz_http/lib/fz_http/crypto.ex rename to apps/domain/fz_http/crypto.ex diff --git a/apps/fz_http/lib/fz_http/devices.ex b/apps/domain/fz_http/devices.ex similarity index 100% rename from apps/fz_http/lib/fz_http/devices.ex rename to apps/domain/fz_http/devices.ex diff --git a/apps/fz_http/lib/fz_http/devices/authorizer.ex b/apps/domain/fz_http/devices/authorizer.ex similarity index 100% rename from apps/fz_http/lib/fz_http/devices/authorizer.ex rename to apps/domain/fz_http/devices/authorizer.ex diff --git a/apps/fz_http/lib/fz_http/devices/device.ex b/apps/domain/fz_http/devices/device.ex similarity index 100% rename from apps/fz_http/lib/fz_http/devices/device.ex rename to apps/domain/fz_http/devices/device.ex diff --git a/apps/fz_http/lib/fz_http/devices/device/changeset.ex b/apps/domain/fz_http/devices/device/changeset.ex similarity index 100% rename from apps/fz_http/lib/fz_http/devices/device/changeset.ex rename to apps/domain/fz_http/devices/device/changeset.ex diff --git a/apps/fz_http/lib/fz_http/devices/device/query.ex b/apps/domain/fz_http/devices/device/query.ex similarity index 100% rename from apps/fz_http/lib/fz_http/devices/device/query.ex rename to apps/domain/fz_http/devices/device/query.ex diff --git a/apps/fz_http/lib/fz_http/devices/stats_updater.ex b/apps/domain/fz_http/devices/stats_updater.ex similarity index 100% rename from apps/fz_http/lib/fz_http/devices/stats_updater.ex rename to apps/domain/fz_http/devices/stats_updater.ex diff --git a/apps/fz_http/lib/fz_http/encrypted/binary.ex b/apps/domain/fz_http/encrypted/binary.ex similarity index 100% rename from apps/fz_http/lib/fz_http/encrypted/binary.ex rename to apps/domain/fz_http/encrypted/binary.ex diff --git a/apps/fz_http/lib/fz_http/encrypted/map.ex b/apps/domain/fz_http/encrypted/map.ex similarity index 100% rename from apps/fz_http/lib/fz_http/encrypted/map.ex rename to apps/domain/fz_http/encrypted/map.ex diff --git a/apps/fz_http/lib/fz_http/name_generator.ex b/apps/domain/fz_http/name_generator.ex similarity index 100% rename from apps/fz_http/lib/fz_http/name_generator.ex rename to apps/domain/fz_http/name_generator.ex diff --git a/apps/fz_http/lib/fz_http/release.ex b/apps/domain/fz_http/release.ex similarity index 100% rename from apps/fz_http/lib/fz_http/release.ex rename to apps/domain/fz_http/release.ex diff --git a/apps/fz_http/lib/fz_http/repo.ex b/apps/domain/fz_http/repo.ex similarity index 100% rename from apps/fz_http/lib/fz_http/repo.ex rename to apps/domain/fz_http/repo.ex diff --git a/apps/fz_http/lib/fz_http/repo/notifier.ex b/apps/domain/fz_http/repo/notifier.ex similarity index 100% rename from apps/fz_http/lib/fz_http/repo/notifier.ex rename to apps/domain/fz_http/repo/notifier.ex diff --git a/apps/fz_http/lib/fz_http/rules.ex b/apps/domain/fz_http/rules.ex similarity index 100% rename from apps/fz_http/lib/fz_http/rules.ex rename to apps/domain/fz_http/rules.ex diff --git a/apps/fz_http/lib/fz_http/rules/authorizer.ex b/apps/domain/fz_http/rules/authorizer.ex similarity index 100% rename from apps/fz_http/lib/fz_http/rules/authorizer.ex rename to apps/domain/fz_http/rules/authorizer.ex diff --git a/apps/fz_http/lib/fz_http/rules/rule.ex b/apps/domain/fz_http/rules/rule.ex similarity index 100% rename from apps/fz_http/lib/fz_http/rules/rule.ex rename to apps/domain/fz_http/rules/rule.ex diff --git a/apps/fz_http/lib/fz_http/rules/rule/changeset.ex b/apps/domain/fz_http/rules/rule/changeset.ex similarity index 100% rename from apps/fz_http/lib/fz_http/rules/rule/changeset.ex rename to apps/domain/fz_http/rules/rule/changeset.ex diff --git a/apps/fz_http/lib/fz_http/rules/rule/query.ex b/apps/domain/fz_http/rules/rule/query.ex similarity index 100% rename from apps/fz_http/lib/fz_http/rules/rule/query.ex rename to apps/domain/fz_http/rules/rule/query.ex diff --git a/apps/fz_http/lib/fz_http/server.ex b/apps/domain/fz_http/server.ex similarity index 100% rename from apps/fz_http/lib/fz_http/server.ex rename to apps/domain/fz_http/server.ex diff --git a/apps/fz_http/lib/fz_http/telemetry.ex b/apps/domain/fz_http/telemetry.ex similarity index 100% rename from apps/fz_http/lib/fz_http/telemetry.ex rename to apps/domain/fz_http/telemetry.ex diff --git a/apps/fz_http/lib/fz_http/telemetry/posthog.ex b/apps/domain/fz_http/telemetry/posthog.ex similarity index 100% rename from apps/fz_http/lib/fz_http/telemetry/posthog.ex rename to apps/domain/fz_http/telemetry/posthog.ex diff --git a/apps/fz_http/lib/fz_http/telemetry/timer.ex b/apps/domain/fz_http/telemetry/timer.ex similarity index 100% rename from apps/fz_http/lib/fz_http/telemetry/timer.ex rename to apps/domain/fz_http/telemetry/timer.ex diff --git a/apps/fz_http/lib/fz_http/types/cidr.ex b/apps/domain/fz_http/types/cidr.ex similarity index 100% rename from apps/fz_http/lib/fz_http/types/cidr.ex rename to apps/domain/fz_http/types/cidr.ex diff --git a/apps/fz_http/lib/fz_http/types/inet.ex b/apps/domain/fz_http/types/inet.ex similarity index 100% rename from apps/fz_http/lib/fz_http/types/inet.ex rename to apps/domain/fz_http/types/inet.ex diff --git a/apps/fz_http/lib/fz_http/types/int4range.ex b/apps/domain/fz_http/types/int4range.ex similarity index 100% rename from apps/fz_http/lib/fz_http/types/int4range.ex rename to apps/domain/fz_http/types/int4range.ex diff --git a/apps/fz_http/lib/fz_http/types/ip.ex b/apps/domain/fz_http/types/ip.ex similarity index 100% rename from apps/fz_http/lib/fz_http/types/ip.ex rename to apps/domain/fz_http/types/ip.ex diff --git a/apps/fz_http/lib/fz_http/types/ip_port.ex b/apps/domain/fz_http/types/ip_port.ex similarity index 100% rename from apps/fz_http/lib/fz_http/types/ip_port.ex rename to apps/domain/fz_http/types/ip_port.ex diff --git a/apps/fz_http/lib/fz_http/types/protocols.ex b/apps/domain/fz_http/types/protocols.ex similarity index 100% rename from apps/fz_http/lib/fz_http/types/protocols.ex rename to apps/domain/fz_http/types/protocols.ex diff --git a/apps/fz_http/lib/fz_http/users.ex b/apps/domain/fz_http/users.ex similarity index 100% rename from apps/fz_http/lib/fz_http/users.ex rename to apps/domain/fz_http/users.ex diff --git a/apps/fz_http/lib/fz_http/users/authorizer.ex b/apps/domain/fz_http/users/authorizer.ex similarity index 100% rename from apps/fz_http/lib/fz_http/users/authorizer.ex rename to apps/domain/fz_http/users/authorizer.ex diff --git a/apps/fz_http/lib/fz_http/users/user.ex b/apps/domain/fz_http/users/user.ex similarity index 100% rename from apps/fz_http/lib/fz_http/users/user.ex rename to apps/domain/fz_http/users/user.ex diff --git a/apps/fz_http/lib/fz_http/users/user/changeset.ex b/apps/domain/fz_http/users/user/changeset.ex similarity index 100% rename from apps/fz_http/lib/fz_http/users/user/changeset.ex rename to apps/domain/fz_http/users/user/changeset.ex diff --git a/apps/fz_http/lib/fz_http/users/user/query.ex b/apps/domain/fz_http/users/user/query.ex similarity index 100% rename from apps/fz_http/lib/fz_http/users/user/query.ex rename to apps/domain/fz_http/users/user/query.ex diff --git a/apps/fz_http/lib/fz_http/validator.ex b/apps/domain/fz_http/validator.ex similarity index 100% rename from apps/fz_http/lib/fz_http/validator.ex rename to apps/domain/fz_http/validator.ex diff --git a/apps/fz_http/lib/fz_http/vault.ex b/apps/domain/fz_http/vault.ex similarity index 100% rename from apps/fz_http/lib/fz_http/vault.ex rename to apps/domain/fz_http/vault.ex diff --git a/apps/fz_http/lib/fz_http/vpn_session_scheduler.ex b/apps/domain/fz_http/vpn_session_scheduler.ex similarity index 100% rename from apps/fz_http/lib/fz_http/vpn_session_scheduler.ex rename to apps/domain/fz_http/vpn_session_scheduler.ex diff --git a/apps/fz_http/lib/fz_http/events.ex b/apps/fz_http/lib/fz_http/events.ex deleted file mode 100644 index 9f80c2d55..000000000 --- a/apps/fz_http/lib/fz_http/events.ex +++ /dev/null @@ -1,93 +0,0 @@ -defmodule FzHttp.Events do - @moduledoc """ - Handles interfacing with other processes in the system. - """ - - alias FzHttp.{Devices, Rules, Users, Notifications} - - require Logger - - # set_config is used because devices need to be re-evaluated in case a - # device is added to a User that's not active. - def add("devices", device) do - with :ok <- GenServer.call(wall_pid(), {:add_device, Devices.setting_projection(device)}), - :ok <- GenServer.call(vpn_pid(), {:set_config, Devices.to_peer_list()}) do - :ok - else - _err -> - Notifications.add(%{ - type: :error, - message: """ - #{device.name} was created successfully but an error occurred applying its - configuration to the WireGuard interface. Check the logs for more - information. - """, - timestamp: DateTime.utc_now(), - user: Users.fetch_user_by_id!(device.user_id).email - }) - end - end - - def add("rules", rule) do - GenServer.call(wall_pid(), {:add_rule, Rules.setting_projection(rule)}) - end - - def add("users", user) do - # Security note: It's important to let an exception here crash this service - # otherwise, nft could have succeeded in adding the user's set but not the rules - # this means that in `update_device` add_device can succeed adding the device to the user's set - # but any rule for the user won't take effect since the user rule doesn't exists. - GenServer.call(wall_pid(), {:add_user, Users.setting_projection(user)}) - end - - def delete("devices", device) do - with :ok <- GenServer.call(wall_pid(), {:delete_device, Devices.setting_projection(device)}), - :ok <- GenServer.call(vpn_pid(), {:remove_peer, device.public_key}) do - :ok - else - _err -> - Notifications.add(%{ - type: :error, - message: """ - #{device.name} was deleted successfully but an error occurred applying its - configuration to the WireGuard interface. Check the logs for more - information. - """, - timestamp: DateTime.utc_now(), - user: Users.fetch_user_by_id!(device.user_id).email - }) - end - end - - def delete("rules", rule) do - GenServer.call(wall_pid(), {:delete_rule, Rules.setting_projection(rule)}) - end - - def delete("users", user) do - GenServer.call(wall_pid(), {:delete_user, Users.setting_projection(user)}) - end - - def set_config do - GenServer.call(vpn_pid(), {:set_config, Devices.to_peer_list()}) - end - - def set_rules do - GenServer.call( - wall_pid(), - {:set_rules, - %{ - users: Users.as_settings(), - devices: Devices.as_settings(), - rules: Rules.as_settings() - }} - ) - end - - def vpn_pid do - :global.whereis_name(:fz_vpn_server) - end - - def wall_pid do - :global.whereis_name(:fz_wall_server) - end -end diff --git a/apps/fz_http/lib/fz_http/notifications.ex b/apps/fz_http/lib/fz_http/notifications.ex deleted file mode 100644 index a905214b0..000000000 --- a/apps/fz_http/lib/fz_http/notifications.ex +++ /dev/null @@ -1,101 +0,0 @@ -defmodule FzHttp.Notifications do - @moduledoc """ - Notification notifications for notifications live view. - """ - use GenServer - - @topic "notifications_live" - alias Phoenix.PubSub - - def start_link(opts \\ []) do - if opts[:name] do - GenServer.start_link(__MODULE__, [], name: opts[:name]) - else - GenServer.start_link(__MODULE__, []) - end - end - - @doc """ - Gets a list of current notifications. - """ - def current, do: current(__MODULE__) - def current(nil), do: current() - def current(pid), do: GenServer.call(pid, :current) - - @doc """ - Add a notification. - """ - def add(notification), do: add(__MODULE__, notification) - def add(nil, notification), do: add(notification) - def add(pid, notification), do: GenServer.call(pid, {:add, notification}) - - @doc """ - Clear all notifications. - """ - def clear_all, do: clear_all(__MODULE__) - def clear_all(nil), do: clear_all() - def clear_all(pid), do: GenServer.call(pid, :clear_all) - - @doc """ - Clear the given notification. - """ - def clear(notification), do: clear(__MODULE__, notification) - def clear(nil, notification), do: clear(notification) - def clear(pid, notification), do: GenServer.call(pid, {:clear, notification}) - - @doc """ - Clear a notification at the given index. - """ - def clear_at(index), do: clear_at(__MODULE__, index) - def clear_at(nil, index), do: clear_at(index) - def clear_at(pid, index), do: GenServer.call(pid, {:clear_at, index}) - - defp broadcast(notifications) do - PubSub.broadcast( - FzHttp.PubSub, - @topic, - {:notifications, notifications} - ) - end - - @impl GenServer - def init(notifications) do - {:ok, notifications} - end - - @impl GenServer - def handle_call(:current, _from, notifications) do - {:reply, notifications, notifications} - end - - @impl GenServer - def handle_call({:add, notification}, _from, notifications) do - new_notifications = [notification | notifications] - broadcast(new_notifications) - - {:reply, :ok, new_notifications} - end - - @impl GenServer - def handle_call(:clear_all, _from, _notifications) do - broadcast([]) - - {:reply, :ok, []} - end - - @impl GenServer - def handle_call({:clear, notification}, _from, notifications) do - new_notifications = Enum.reject(notifications, &(&1 == notification)) - broadcast(new_notifications) - - {:reply, :ok, new_notifications} - end - - @impl GenServer - def handle_call({:clear_at, index}, _from, notifications) do - {_, new_notifications} = List.pop_at(notifications, index) - broadcast(new_notifications) - - {:reply, :ok, new_notifications} - end -end diff --git a/apps/fz_vpn/.formatter.exs b/apps/fz_vpn/.formatter.exs deleted file mode 100644 index 7f9277b11..000000000 --- a/apps/fz_vpn/.formatter.exs +++ /dev/null @@ -1,9 +0,0 @@ -[ - locals_without_parens: [], - import_deps: [], - inputs: [ - "*.{ex,exs}", - "{lib,test,priv}/**/*.{ex,exs}" - ], - plugins: [] -] diff --git a/apps/fz_vpn/.gitignore b/apps/fz_vpn/.gitignore deleted file mode 100644 index f94d3cae0..000000000 --- a/apps/fz_vpn/.gitignore +++ /dev/null @@ -1,23 +0,0 @@ -# The directory Mix will write compiled artifacts to. -/_build/ - -# If you run "mix test --cover", coverage assets end up here. -/cover/ - -# The directory Mix downloads your dependencies sources to. -/deps/ - -# Where third-party dependencies like ExDoc output generated docs. -/doc/ - -# Ignore .fetch files in case you like to edit your project deps locally. -/.fetch - -# If the VM crashes, it generates a dump, let's ignore it too. -erl_crash.dump - -# Also ignore archive artifacts (built via "mix archive.build"). -*.ez - -# Ignore package tarball (built via "mix hex.build"). -cf_vpn-*.tar diff --git a/apps/fz_vpn/README.md b/apps/fz_vpn/README.md deleted file mode 100644 index 6922cac98..000000000 --- a/apps/fz_vpn/README.md +++ /dev/null @@ -1,3 +0,0 @@ -# FzVpn - -Elixir/OTP frontend to WireGuard. diff --git a/apps/fz_vpn/coveralls.json b/apps/fz_vpn/coveralls.json deleted file mode 100644 index 1b7743591..000000000 --- a/apps/fz_vpn/coveralls.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "skip_files": [ - "lib/fz_vpn/cli/live.ex", - "test" - ] -} diff --git a/apps/fz_vpn/lib/fz_vpn.ex b/apps/fz_vpn/lib/fz_vpn.ex deleted file mode 100644 index 3684f7d59..000000000 --- a/apps/fz_vpn/lib/fz_vpn.ex +++ /dev/null @@ -1,5 +0,0 @@ -defmodule FzVpn do - @moduledoc """ - Documentation for `FzVpn`. - """ -end diff --git a/apps/fz_vpn/lib/fz_vpn/application.ex b/apps/fz_vpn/lib/fz_vpn/application.ex deleted file mode 100644 index 090fee4cf..000000000 --- a/apps/fz_vpn/lib/fz_vpn/application.ex +++ /dev/null @@ -1,12 +0,0 @@ -defmodule FzVpn.Application do - use Application - - def start(_type, _args) do - opts = [strategy: :one_for_one, name: __MODULE__.Supervisor] - Supervisor.start_link(children(), opts) - end - - defp children do - Application.fetch_env!(:fz_vpn, :supervised_children) - end -end diff --git a/apps/fz_vpn/lib/fz_vpn/interface.ex b/apps/fz_vpn/lib/fz_vpn/interface.ex deleted file mode 100644 index d24248696..000000000 --- a/apps/fz_vpn/lib/fz_vpn/interface.ex +++ /dev/null @@ -1,205 +0,0 @@ -defmodule FzVpn.Interface do - @moduledoc """ - This module has functions to create interfaces, set configurations on them, - and get peer info via [WireGuard](https://wireguard.com) - """ - import FzVpn.Interface.WGAdapter - - alias Wireguardex.DeviceConfigBuilder - alias Wireguardex.PeerConfigBuilder - - require Logger - - @doc """ - Set an interface by name with its peers. If the interface does not exist, it - will be created. - - ## Options - - * `:private_key` - the interface's private key will be set - * `:listen_port - the interface's listening port will be set - - If successful we return an :ok status. If interface fails to be set, - `{:error, error_info}` will be logged and returned. - """ - def set(name, peers, opts \\ []) do - private_key = opts[:private_key] - listen_port = opts[:listen_port] - - peer_configs = - for {public_key, settings} <- peers do - PeerConfigBuilder.peer_config() - |> PeerConfigBuilder.public_key(public_key) - |> PeerConfigBuilder.preshared_key(settings.preshared_key) - |> PeerConfigBuilder.allowed_ips(String.split(settings.allowed_ips, ",")) - end - - result = - DeviceConfigBuilder.device_config() - |> DeviceConfigBuilder.private_key(private_key) - |> DeviceConfigBuilder.listen_port(listen_port) - |> DeviceConfigBuilder.peers(peer_configs) - |> wg_adapter().set_device(name) - - case result do - :ok -> - :ok - - {:error, error_info} -> - Logger.error("Failed to set interface #{name}: #{error_info}") - result - end - end - - @doc """ - Get an interface by its name. - - If successful we return an `{:ok, Device}`. If the interface fails to be - retrieved, return `{:error, error_info}`. - """ - def get(name) do - result = wg_adapter().get_device(name) - - case result do - {:ok, device} -> - {:ok, device} - - {:error, error_info} -> - Logger.error("Failed to get interface #{name}: #{error_info}") - result - end - end - - @doc """ - Get a list of interface names. - - If successful we return `{:ok, [Device]}. If getting the list fails, return - '{:error, error_info}'. - """ - def list_names do - result = wg_adapter().list_devices() - - case result do - {:ok, iface_names} -> - {:ok, iface_names} - - {:error, error_info} -> - Logger.error("Failed to get list of interface names: #{error_info}") - result - end - end - - @doc """ - Delete an interface. - - If successful we return an :ok status. If interface fails to be deleted, - `{:error, error_info}` will be logged and returned. - """ - def delete(name) do - result = wg_adapter().delete_device(name) - - case result do - :ok -> - :ok - - {:error, error_info} -> - Logger.error("Failed to delete interface #{name}: #{error_info}") - result - end - end - - @doc """ - Remove a peer from an interface. - - If successful we return an :ok status. If the peer fails to be removed from - the interface, `{:error, error_info}` will be logged and returned. - """ - def remove_peer(name, public_key) do - result = wg_adapter().remove_peer(name, public_key) - - case result do - :ok -> - :ok - - {:error, error_info} -> - Logger.error("Failed to remove peer from interface #{name}: #{error_info}") - result - end - end - - @doc """ - Return a map of information on all the current peers of the interface. - - If successful we return the map of peer information. If the device fails to be - retrieved for info, `{:error, error_info}` will be logged and returned. - """ - def dump(name) do - result = get(name) - - case result do - {:ok, device} -> - peers_to_dump_map(device.peers) - - {:error, error_info} -> - Logger.error("Failed to get interface #{name} stats: #{error_info}") - result - end - end - - defp peers_to_dump_map(peers) do - Map.new(peers, fn peer -> - dump = - Map.from_struct(peer.config) - |> Map.merge(Map.from_struct(peer.stats)) - |> Enum.map(&dump_field/1) - |> Map.new() - # dump these fields from the peer info - |> Map.take([ - :preshared_key, - :endpoint, - :allowed_ips, - :persistent_keepalive, - :latest_handshake, - :rx_bytes, - :tx_bytes - ]) - - { - peer.config.public_key, - dump - } - end) - end - - defp dump_field({field, value}) do - case {field, value} do - {:allowed_ips, allowed_ips} -> - {:allowed_ips, allowed_ips_to_str(allowed_ips)} - - {:persistent_keepalive_interval, n} -> - {:persistent_keepalive, persistent_keepalive_to_str(n)} - - {:endpoint, nil} -> - {:endpoint, "(none)"} - - {:last_handshake_time, t} -> - {:latest_handshake, latest_handshake_to_str(t)} - - {:preshared_key, nil} -> - {:preshared_key, "(none)"} - - _ -> - {field, to_string(value)} - end - end - - defp allowed_ips_to_str([]), do: "(none)" - defp allowed_ips_to_str(allowed_ips) when is_binary(allowed_ips), do: allowed_ips - defp allowed_ips_to_str(allowed_ips), do: Enum.join(allowed_ips, ",") - - defp latest_handshake_to_str(t) when is_nil(t), do: "0" - defp latest_handshake_to_str(t), do: to_string(t) - - defp persistent_keepalive_to_str(n) when is_nil(n) or n == 0, do: "off" - defp persistent_keepalive_to_str(n), do: to_string(n) -end diff --git a/apps/fz_vpn/lib/fz_vpn/interface/wg_adapter.ex b/apps/fz_vpn/lib/fz_vpn/interface/wg_adapter.ex deleted file mode 100644 index 156178915..000000000 --- a/apps/fz_vpn/lib/fz_vpn/interface/wg_adapter.ex +++ /dev/null @@ -1,17 +0,0 @@ -defmodule FzVpn.Interface.WGAdapter do - @moduledoc """ - This module determines by application environment which WireGuard adapter to - use: `Live` or `Sandbox`. - - `Live` is used for environments where WireGuard is available and `Sandbox` is - used for environments where it isn't. - - The `Sandbox` adapter is mocked with a simple GenServer to store state. When it - is called for the first time, it spawns the Sandbox GenServer and links it to the current - process. This allows the current process to know which GenServer to call during tests. - """ - - def wg_adapter do - Application.fetch_env!(:fz_vpn, :wg_adapter) - end -end diff --git a/apps/fz_vpn/lib/fz_vpn/interface/wg_adapter/live.ex b/apps/fz_vpn/lib/fz_vpn/interface/wg_adapter/live.ex deleted file mode 100644 index 6b1a624dc..000000000 --- a/apps/fz_vpn/lib/fz_vpn/interface/wg_adapter/live.ex +++ /dev/null @@ -1,11 +0,0 @@ -defmodule FzVpn.Interface.WGAdapter.Live do - @moduledoc """ - The live WireGuard adapter. - """ - - defdelegate get_device(name), to: Wireguardex - defdelegate list_devices, to: Wireguardex - defdelegate set_device(config, name), to: Wireguardex - defdelegate delete_device(name), to: Wireguardex - defdelegate remove_peer(name, public_key), to: Wireguardex -end diff --git a/apps/fz_vpn/lib/fz_vpn/interface/wg_adapter/sandbox.ex b/apps/fz_vpn/lib/fz_vpn/interface/wg_adapter/sandbox.ex deleted file mode 100644 index 2b3ae8962..000000000 --- a/apps/fz_vpn/lib/fz_vpn/interface/wg_adapter/sandbox.ex +++ /dev/null @@ -1,101 +0,0 @@ -defmodule FzVpn.Interface.WGAdapter.Sandbox do - @moduledoc """ - The sandbox WireGuard adapter. - """ - - use GenServer - - def start_link(_) do - GenServer.start_link(__MODULE__, %{}, name: __MODULE__) - end - - def get_device(name) do - GenServer.call(__MODULE__, {:get_device, name}) - end - - def list_devices do - GenServer.call(__MODULE__, {:list_devices}) - end - - def set_device(config, name) do - GenServer.call(__MODULE__, {:set_device, config, name}) - end - - def delete_device(name) do - GenServer.call(__MODULE__, {:delete_device, name}) - end - - def remove_peer(name, public_key) do - GenServer.call(__MODULE__, {:remove_peer, name, public_key}) - end - - @impl GenServer - def init(_) do - {:ok, %{}} - end - - @impl GenServer - def handle_call({:get_device, name}, _from, devices) do - {:reply, {:ok, Map.get(devices, name)}, devices} - end - - @impl GenServer - def handle_call({:list_devices}, _from, devices) do - {:reply, {:ok, Map.keys(devices)}, devices} - end - - @impl GenServer - def handle_call({:set_device, config, name}, _from, devices) do - public_key = - if config.private_key do - {:ok, public_key} = Wireguardex.get_public_key(config.private_key) - public_key - end - - peers = - config.peers - |> Enum.map(fn peer -> - %Wireguardex.PeerInfo{ - config: peer, - stats: %Wireguardex.PeerStats{} - } - end) - - device = %Wireguardex.Device{ - name: name, - public_key: public_key, - private_key: config.private_key, - listen_port: config.listen_port, - peers: peers - } - - {:reply, :ok, Map.put(devices, name, device)} - end - - @impl GenServer - def handle_call({:delete_device, name}, _from, devices) do - {:reply, :ok, Map.delete(devices, name)} - end - - @impl GenServer - def handle_call({:remove_peer, name, public_key}, _from, devices) do - device = Map.get(devices, name) - - peers = - Enum.reject(device.peers, fn peer -> - peer.config.public_key == public_key - end) - - new_device = %Wireguardex.Device{ - name: device.name, - public_key: device.public_key, - private_key: device.private_key, - fwmark: device.fwmark, - listen_port: device.listen_port, - peers: peers, - linked_name: device.linked_name - } - - {:reply, :ok, Map.put(devices, name, new_device)} - end -end diff --git a/apps/fz_vpn/lib/fz_vpn/keypair.ex b/apps/fz_vpn/lib/fz_vpn/keypair.ex deleted file mode 100644 index b663d2f62..000000000 --- a/apps/fz_vpn/lib/fz_vpn/keypair.ex +++ /dev/null @@ -1,33 +0,0 @@ -defmodule FzVpn.Keypair do - @moduledoc """ - Utilities for persisting / generating keypairs. - """ - - def load_or_generate_private_key do - path = Application.fetch_env!(:fz_vpn, :wireguard_private_key_path) - - private_key = - if File.exists?(path) && File.stat!(path).size > 0 do - File.read!(path) - |> String.trim() - else - key = Wireguardex.generate_private_key() - write_private_key(path, key) - key - end - - set_public_key(private_key) - private_key - end - - defp set_public_key(private_key) do - {:ok, public_key} = Wireguardex.get_public_key(private_key) - Application.put_env(:fz_vpn, :wireguard_public_key, public_key, persistent: true) - end - - defp write_private_key(path, private_key) do - File.touch!(path) - File.chmod!(path, 0o600) - File.write!(path, private_key) - end -end diff --git a/apps/fz_vpn/lib/fz_vpn/server.ex b/apps/fz_vpn/lib/fz_vpn/server.ex deleted file mode 100644 index ea4f6d174..000000000 --- a/apps/fz_vpn/lib/fz_vpn/server.ex +++ /dev/null @@ -1,91 +0,0 @@ -defmodule FzVpn.Server do - @moduledoc """ - Functions for reading / writing the WireGuard config. - """ - - use GenServer - require Logger - - alias FzVpn.Interface - alias FzVpn.Keypair - - @init_timeout 10_000 - - def start_link(_) do - GenServer.start_link(__MODULE__, %{}, name: {:global, :fz_vpn_server}) - end - - @impl GenServer - def init(_config) do - setup_interface() - {:ok, peers} = GenServer.call(http_pid(), :load_peers, @init_timeout) - config = peers_to_config(peers) - apply_config_diff(config) - end - - @impl GenServer - def handle_call({:remove_peer, public_key}, _from, config) do - case Interface.remove_peer(iface_name(), public_key) do - :ok -> - {:reply, :ok, Map.delete(config, public_key)} - - err -> - {:reply, err, config} - end - end - - @impl GenServer - def handle_call({:set_config, peers}, _from, config) do - new_config = peers_to_config(peers) - {res, resp} = apply_config_diff(config, new_config) - {:reply, res, resp} - end - - @doc """ - Determines which peers to remove, add, and change and sets them on the WireGuard interface. - """ - def apply_config_diff(old_config \\ %{}, new_config) do - delete_old_peers(old_config, new_config) - update_changed_peers(old_config, new_config) - end - - def iface_name do - Application.get_env(:fz_vpn, :wireguard_interface_name, "wg-firezone") - end - - def http_pid do - :global.whereis_name(:fz_http_server) - end - - defp setup_interface do - private_key = Keypair.load_or_generate_private_key() - listen_port = Application.fetch_env!(:fz_vpn, :wireguard_port) - Interface.set(iface_name(), %{}, private_key: private_key, listen_port: listen_port) - end - - defp delete_old_peers(old_config, new_config) do - for public_key <- Map.keys(old_config) -- Map.keys(new_config) do - Interface.remove_peer(iface_name(), public_key) - end - end - - defp update_changed_peers(old_config, new_config) do - new_config - |> Map.filter(fn {public_key, settings} -> Map.get(old_config, public_key) != settings end) - |> set_peers() - |> case do - :ok -> {:ok, new_config} - {:error, _error_info} -> {:error, old_config} - end - end - - defp set_peers(peers) do - Interface.set(iface_name(), peers) - end - - defp peers_to_config(peers) do - Map.new(peers, fn peer -> - {peer.public_key, %{allowed_ips: peer.inet, preshared_key: peer.preshared_key}} - end) - end -end diff --git a/apps/fz_vpn/lib/fz_vpn/stats_push_service.ex b/apps/fz_vpn/lib/fz_vpn/stats_push_service.ex deleted file mode 100644 index 0689c1917..000000000 --- a/apps/fz_vpn/lib/fz_vpn/stats_push_service.ex +++ /dev/null @@ -1,31 +0,0 @@ -defmodule FzVpn.StatsPushService do - @moduledoc """ - Service to periodically push WireGuard statistics to fz_http. - """ - use GenServer - - alias FzVpn.Interface - alias FzVpn.Server - - # 60 seconds - @interval 60_000 - - def start_link(_) do - GenServer.start_link(__MODULE__, %{}, []) - end - - @impl GenServer - def init(state) do - :timer.send_interval(@interval, :perform) - {:ok, state} - end - - @impl GenServer - def handle_info(:perform, _state) do - {:noreply, push_stats()} - end - - def push_stats do - GenServer.call(Server.http_pid(), {:update_device_stats, Interface.dump(Server.iface_name())}) - end -end diff --git a/apps/fz_vpn/mix.exs b/apps/fz_vpn/mix.exs deleted file mode 100644 index afa4fa17c..000000000 --- a/apps/fz_vpn/mix.exs +++ /dev/null @@ -1,46 +0,0 @@ -defmodule FzVpn.MixProject do - use Mix.Project - - def version do - # Use dummy version for dev and test - System.get_env("VERSION", "0.0.0+git.0.deadbeef") - end - - def project do - [ - app: :fz_vpn, - version: version(), - build_path: "../../_build", - config_path: "../../config/config.exs", - deps_path: "../../deps", - lockfile: "../../mix.lock", - elixir: "~> 1.12", - start_permanent: Mix.env() == :prod, - test_coverage: [tool: ExCoveralls], - preferred_cli_env: [ - coveralls: :test, - "coveralls.detail": :test, - "coveralls.post": :test, - "coveralls.html": :test - ], - deps: deps() - ] - end - - # Run "mix help compile.app" to learn about applications. - def application do - [ - extra_applications: [:logger], - mod: {FzVpn.Application, []}, - registered: [:fz_vpn_server] - ] - end - - # Run "mix help deps" to learn about dependencies. - defp deps do - [ - {:fz_http, in_umbrella: true}, - {:wireguardex, "~> 0.3.5"} - ] - end -end diff --git a/apps/fz_vpn/test/fixtures/.gitkeep b/apps/fz_vpn/test/fixtures/.gitkeep deleted file mode 100644 index e69de29bb..000000000 diff --git a/apps/fz_vpn/test/fz_vpn/interface_test.exs b/apps/fz_vpn/test/fz_vpn/interface_test.exs deleted file mode 100644 index b5ee6064f..000000000 --- a/apps/fz_vpn/test/fz_vpn/interface_test.exs +++ /dev/null @@ -1,85 +0,0 @@ -defmodule FzVpn.InterfaceTest do - use ExUnit.Case, async: true - - alias FzVpn.Interface - alias FzVpn.Server - - test "delete interface" do - name = "wg-delete" - :ok = Interface.set(name, %{}) - - assert :ok == Interface.delete(name) - end - - test "list interface names" do - additional_names = ["wg0-list", "wg1-list"] - Enum.each(additional_names, fn name -> Interface.set(name, %{}) end) - {:ok, names} = Interface.list_names() - Enum.each(additional_names, fn name -> :ok = Interface.delete(name) end) - - assert names == [Server.iface_name()] ++ additional_names - end - - test "remove peer from interface" do - name = "wg-remove-peer" - public_key = "+wEYaT5kNg7mp+KbDMjK0FkQBtrN8RprHxudAgS0vS0=" - - peers = %{ - public_key => %{ - allowed_ips: "10.3.2.7/32,fd00::3:2:7/128", - preshared_key: nil - } - } - - :ok = Interface.set(name, peers) - :ok = Interface.remove_peer(name, public_key) - {:ok, device} = Interface.get(name) - :ok = Interface.delete(name) - - assert device.peers == [] - end - - describe "getting interface peer stats" do - @expected_interface_info %{ - "+wEYaT5kNg7mp+KbDMjK0FkQBtrN8RprHxudAgS0vS0=" => %{ - allowed_ips: "10.3.2.7/32,fd00::3:2:7/128", - endpoint: "(none)", - latest_handshake: "0", - persistent_keepalive: "off", - preshared_key: "(none)", - rx_bytes: "0", - tx_bytes: "0" - }, - "JOvewkquusVzBHIRjvq32gE4rtsmDKyGh8ubhT4miAY=" => %{ - allowed_ips: "10.3.2.8/32,fd00::3:2:8/128", - endpoint: "(none)", - latest_handshake: "0", - persistent_keepalive: "off", - preshared_key: "(none)", - rx_bytes: "0", - tx_bytes: "0" - } - } - - test "dump interface info" do - name = "wg-dump" - - peers = %{ - "+wEYaT5kNg7mp+KbDMjK0FkQBtrN8RprHxudAgS0vS0=" => %{ - allowed_ips: "10.3.2.7/32,fd00::3:2:7/128", - preshared_key: nil - }, - "JOvewkquusVzBHIRjvq32gE4rtsmDKyGh8ubhT4miAY=" => %{ - allowed_ips: "10.3.2.8/32,fd00::3:2:8/128", - preshared_key: nil - } - } - - :ok = Interface.set(name, peers) - interface_info = Interface.dump(name) - :ok = Interface.delete(name) - - assert interface_info == @expected_interface_info - end - end -end diff --git a/apps/fz_vpn/test/fz_vpn/server_test.exs b/apps/fz_vpn/test/fz_vpn/server_test.exs deleted file mode 100644 index 58935eb69..000000000 --- a/apps/fz_vpn/test/fz_vpn/server_test.exs +++ /dev/null @@ -1,55 +0,0 @@ -defmodule FzVpn.ServerTest do - use ExUnit.Case, async: true - - setup %{stubbed_config: config} do - test_pid = :global.whereis_name(:fz_vpn_server) - :ok = GenServer.call(test_pid, {:set_config, config}) - - %{test_pid: test_pid} - end - - describe "state" do - @pubkey "2Bp11cX3ETPs4/bbKdn44OywJAqD6XuzWG6VCrlSzXI=" - @psk "sGaRdRnjo58qCuNnb4zIwAfZa0mOmD6aDfsxye9Tw3s=" - @key1 "KGIx2Yt8S+dc2886Y9H4lrFzm3Hh7f//Ix0Ip/mdX2k=" - @key2 "MDxx3EkWIBI1KfBhnAdwfdqGcFMKz32+PgIOro4g9Eo=" - @key3 "wMc2ntAv2w233Qsy+VMfFHzF4J4rPaj2+HYeFV99YH8=" - @key4 "wN2yynjMdSzFcVrzfl7v89YOuBfNWhMAklgfeA3PQG0=" - @key5 "8IkpsAXiqhqNdc9PJS76YeJjig4lyTBaf8Rm7gTApXk=" - - @single_peer [ - %{public_key: @pubkey, preshared_key: @psk, inet: "127.0.0.1/32,::1/128"} - ] - @many_peers [ - %{public_key: @key1, preshared_key: @psk, inet: "0.0.0.0/32,::1/128"}, - %{public_key: @key2, preshared_key: @psk, inet: "127.0.0.1/32,::1/128"}, - %{public_key: @key3, preshared_key: @psk, inet: "127.0.0.1/32,::1/128"}, - %{public_key: @key4, preshared_key: @psk, inet: "127.0.0.1/32,::1/128"} - ] - - @tag stubbed_config: @single_peer - test "removes peers from config when removed", %{test_pid: test_pid} do - GenServer.call(test_pid, {:remove_peer, @pubkey}) - - assert :sys.get_state(test_pid) == %{} - end - - @tag stubbed_config: @many_peers - test "calcs diff and sets only the diff", %{test_pid: test_pid} do - new_peers = [%{public_key: @key5, inet: "1.1.1.1/32,::2/128", preshared_key: @psk}] - - assert :sys.get_state(test_pid) == %{ - @key1 => %{allowed_ips: "0.0.0.0/32,::1/128", preshared_key: @psk}, - @key2 => %{allowed_ips: "127.0.0.1/32,::1/128", preshared_key: @psk}, - @key3 => %{allowed_ips: "127.0.0.1/32,::1/128", preshared_key: @psk}, - @key4 => %{allowed_ips: "127.0.0.1/32,::1/128", preshared_key: @psk} - } - - :ok = GenServer.call(test_pid, {:set_config, new_peers}) - - assert :sys.get_state(test_pid) == %{ - @key5 => %{allowed_ips: "1.1.1.1/32,::2/128", preshared_key: @psk} - } - end - end -end diff --git a/apps/fz_vpn/test/fz_vpn/stats_push_service_test.exs b/apps/fz_vpn/test/fz_vpn/stats_push_service_test.exs deleted file mode 100644 index a3a7eb2ea..000000000 --- a/apps/fz_vpn/test/fz_vpn/stats_push_service_test.exs +++ /dev/null @@ -1,3 +0,0 @@ -defmodule FzVpn.StatsPushServiceTest do - use ExUnit.Case, async: true -end diff --git a/apps/fz_vpn/test/fz_vpn_test.exs b/apps/fz_vpn/test/fz_vpn_test.exs deleted file mode 100644 index f36e91ac7..000000000 --- a/apps/fz_vpn/test/fz_vpn_test.exs +++ /dev/null @@ -1,4 +0,0 @@ -defmodule FzVpnTest do - use ExUnit.Case - doctest FzVpn -end diff --git a/apps/fz_vpn/test/test_helper.exs b/apps/fz_vpn/test/test_helper.exs deleted file mode 100644 index 869559e70..000000000 --- a/apps/fz_vpn/test/test_helper.exs +++ /dev/null @@ -1 +0,0 @@ -ExUnit.start() diff --git a/apps/fz_wall/.formatter.exs b/apps/fz_wall/.formatter.exs deleted file mode 100644 index 7f9277b11..000000000 --- a/apps/fz_wall/.formatter.exs +++ /dev/null @@ -1,9 +0,0 @@ -[ - locals_without_parens: [], - import_deps: [], - inputs: [ - "*.{ex,exs}", - "{lib,test,priv}/**/*.{ex,exs}" - ], - plugins: [] -] diff --git a/apps/fz_wall/.gitignore b/apps/fz_wall/.gitignore deleted file mode 100644 index b80a1c799..000000000 --- a/apps/fz_wall/.gitignore +++ /dev/null @@ -1,23 +0,0 @@ -# The directory Mix will write compiled artifacts to. -/_build/ - -# If you run "mix test --cover", coverage assets end up here. -/cover/ - -# The directory Mix downloads your dependencies sources to. -/deps/ - -# Where third-party dependencies like ExDoc output generated docs. -/doc/ - -# Ignore .fetch files in case you like to edit your project deps locally. -/.fetch - -# If the VM crashes, it generates a dump, let's ignore it too. -erl_crash.dump - -# Also ignore archive artifacts (built via "mix archive.build"). -*.ez - -# Ignore package tarball (built via "mix hex.build"). -firewall_daemon-*.tar diff --git a/apps/fz_wall/README.md b/apps/fz_wall/README.md deleted file mode 100644 index 4b95f509a..000000000 --- a/apps/fz_wall/README.md +++ /dev/null @@ -1,3 +0,0 @@ -# FzWall - -Elixir/OTP frontend to `nft`. diff --git a/apps/fz_wall/lib/fz_wall.ex b/apps/fz_wall/lib/fz_wall.ex deleted file mode 100644 index f91defcf6..000000000 --- a/apps/fz_wall/lib/fz_wall.ex +++ /dev/null @@ -1,18 +0,0 @@ -defmodule FzWall do - @moduledoc """ - Documentation for FzWall. - """ - - @doc """ - Hello world. - - ## Examples - - iex> FzWall.hello() - :world - - """ - def hello do - :world - end -end diff --git a/apps/fz_wall/lib/fz_wall/application.ex b/apps/fz_wall/lib/fz_wall/application.ex deleted file mode 100644 index fcf54a1da..000000000 --- a/apps/fz_wall/lib/fz_wall/application.ex +++ /dev/null @@ -1,18 +0,0 @@ -defmodule FzWall.Application do - # See https://hexdocs.pm/elixir/Application.html - # for more information on OTP Applications - @moduledoc false - - use Application - - def start(_type, _args) do - children = [ - FzWall.Server - ] - - # See https://hexdocs.pm/elixir/Supervisor.html - # for other strategies and supported options - opts = [strategy: :one_for_one, name: __MODULE__.Supervisor] - Supervisor.start_link(children, opts) - end -end diff --git a/apps/fz_wall/lib/fz_wall/cli.ex b/apps/fz_wall/lib/fz_wall/cli.ex deleted file mode 100644 index 7e4793532..000000000 --- a/apps/fz_wall/lib/fz_wall/cli.ex +++ /dev/null @@ -1,9 +0,0 @@ -defmodule FzWall.CLI do - @moduledoc """ - Determines adapter to use for CLI commands. - """ - - def cli do - Application.fetch_env!(:fz_wall, :cli) - end -end diff --git a/apps/fz_wall/lib/fz_wall/cli/helpers/nft.ex b/apps/fz_wall/lib/fz_wall/cli/helpers/nft.ex deleted file mode 100644 index 69cff484a..000000000 --- a/apps/fz_wall/lib/fz_wall/cli/helpers/nft.ex +++ /dev/null @@ -1,290 +0,0 @@ -defmodule FzWall.CLI.Helpers.Nft do - @moduledoc """ - Helper module concerning nft commands - """ - import FzWall.Shell - require Logger - @table_name "firezone" - @main_chain "forward" - - @doc """ - Insert a nft filter rule - """ - def insert_filter_rule(chain, type, dest_set, action, layer4) do - insert_rule(chain, rule_filter_match_str(type, dest_set, action, layer4)) - end - - @doc """ - Insert a nft jump rule - """ - def insert_dev_rule(ip_type, source_set, jump_chain) do - insert_rule(@main_chain, rule_dev_match_str(ip_type, source_set, jump_chain)) - end - - @doc """ - Remove device-related rule - """ - # Note: we don't need remove_filter_rule because the chains are removed all together - def remove_dev_rule(ip_type, source_set, jump_chain) do - delete_rule_matching(rule_dev_match_str(ip_type, source_set, jump_chain)) - end - - @doc """ - Add element to set - """ - def add_elem(set, ip, nil, nil) do - add_ip_elem(set, ip) - end - - def add_elem(set, ip, proto, ports) do - add_elem_exec(set, get_elem(ip, proto, ports)) - end - - def add_elem(set, ip) do - add_ip_elem(set, ip) - end - - defp add_ip_elem(set, ip) do - add_elem_exec(set, get_elem(ip)) - end - - @doc """ - Deletes an element from a nft set - """ - def delete_elem(set, ip) do - delete_ip_elem(set, ip) - end - - def delete_elem(set, ip, nil, nil) do - delete_ip_elem(set, ip) - end - - def delete_elem(set, ip, proto, ports) do - delete_elem_exec(set, get_elem(ip, proto, ports)) - end - - defp delete_ip_elem(set, ip) do - delete_elem_exec(set, get_elem(ip)) - end - - @doc """ - Adds a nft dev set - """ - def add_dev_set(name, ip_type) do - add_set(name, dev_set_type(ip_type)) - end - - @doc """ - Adds a nft filter set - """ - def add_filter_set(name, ip_type, layer4) do - add_set(name, filter_set_type(ip_type, layer4)) - end - - @doc """ - Deletes a nft set - """ - def delete_set(name) do - exec!(""" - #{nft()} 'delete set inet #{@table_name} #{name}' - """) - end - - @doc """ - Sets up firezone table. - """ - def setup_table do - exec!("#{nft()} create table inet #{@table_name}") - end - - @doc """ - Sets up firezone chains. - """ - def setup_chains do - exec!( - "#{nft()} 'add chain inet #{@table_name} #{@main_chain} " <> - "{ type filter hook forward priority 0 ; policy accept ; }'" - ) - - exec!( - "#{nft()} 'add chain inet #{@table_name} postrouting " <> - "{ type nat hook postrouting priority 100 ; }'" - ) - - setup_masquerade() - end - - @doc """ - Adds a regular nftable chain(not base) - """ - def add_chain(chain_name) do - exec!("#{nft()} 'add chain inet #{@table_name} #{chain_name}'") - end - - @doc """ - Deletes a regular nftable chain(not base) - """ - def delete_chain(chain_name) do - exec!("#{nft()} 'delete chain inet #{@table_name} #{chain_name}'") - end - - defp setup_masquerade do - if masquerade_ipv4?() do - setup_masquerade(:ipv4) - end - - if masquerade_ipv6?() do - setup_masquerade(:ipv6) - end - end - - defp setup_masquerade(proto) do - File.ls!("/sys/class/net/") - |> Enum.reject(&skip_masquerade_for_interface?/1) - |> Enum.map(fn int -> - exec!( - "#{nft()} 'add rule inet #{@table_name} postrouting oifname " <> - "#{int} meta nfproto #{proto} masquerade persistent'" - ) - end) - end - - defp skip_masquerade_for_interface?(int) do - int in ["lo", wireguard_interface_name()] - end - - defp masquerade_ipv4? do - Application.fetch_env!(:fz_wall, :wireguard_ipv4_masquerade) - end - - defp masquerade_ipv6? do - Application.fetch_env!(:fz_wall, :wireguard_ipv6_masquerade) - end - - @doc """ - Deletes nft tables (This will remove) - """ - def teardown_table do - if table_exists?() do - exec!("#{nft()} delete table inet #{@table_name}") - end - end - - defp nft do - Application.fetch_env!(:fz_wall, :nft_path) - end - - defp table_exists? do - cmd = "#{nft()} list table inet #{@table_name}" - - case bash(cmd) do - {_result, 0} -> - true - - {error, _exit_code} -> - if error =~ ~r/No such file or directory|does not exist/ do - false - else - raise """ - Unknown Error from command #{cmd}. Error: - #{error} - """ - end - end - end - - defp delete_rule_matching(rule_str) do - rules = exec!("#{nft()} -a list table inet #{@table_name}") - - # When a rule is deleted the others might change handle so we need to - # re-scan each time. - case rule_handle_regex(~r/^\s*#{rule_str}.*# handle (?\d+)/m, rules) do - nil -> - Logger.warning( - "Tried to delete a rule with string: #{rule_str} but it wasn't found, might have been removed manually" - ) - - handle -> - exec!("#{nft()} delete rule inet #{@table_name} #{@main_chain} handle #{handle}") - end - end - - defp wireguard_interface_name do - Application.fetch_env!(:fz_wall, :wireguard_interface_name) - end - - defp rule_handle_regex(regex, rules) do - Regex.run(regex, rules, capture: :all_names) - end - - defp filter_set_type(:ip, false), do: "ipv4_addr" - defp filter_set_type(:ip6, false), do: "ipv6_addr" - - defp filter_set_type(ip_type, true), - do: "#{filter_set_type(ip_type, false)} . inet_proto . inet_service" - - defp dev_set_type(ip_type), do: filter_set_type(ip_type, false) - - defp additional_matches do - "meta iifname #{wireguard_interface_name()}" - end - - defp rule_filter_match_str(type, dest_set, action, false) do - "#{type} daddr @#{dest_set} #{additional_matches()} #{action}" - end - - defp rule_filter_match_str(type, dest_set, action, true) do - "#{type} daddr . meta l4proto . th dport @#{dest_set} #{additional_matches()} #{action}" - end - - defp rule_dev_match_str(ip_type, source_set, jump_chain) do - "#{ip_type} saddr @#{source_set} jump #{jump_chain}" - end - - defp insert_rule(chain, rule_str) do - exec!(""" - #{nft()} 'insert rule inet #{@table_name} #{chain} #{rule_str}' - """) - end - - defp delete_elem_exec(set, elem) do - exec!(""" - #{nft()} 'delete element inet #{@table_name} #{set} { #{elem} }' - """) - end - - defp add_set(name, type) do - exec!(""" - #{nft()} 'add set inet #{@table_name} #{name} { type #{type} ; flags interval ; }' - """) - end - - defp add_elem_exec(set, elem) do - exec!(""" - #{nft()} 'add element inet #{@table_name} #{set} { #{elem} }' - """) - end - - def get_elem(ip) do - "#{standardized_inet(ip)}" - end - - def get_elem(ip, proto, ports) do - "#{standardized_inet(ip)} . #{proto} . #{ports}" - end - - @doc """ - Standardize IP addresses and CIDR ranges so that they can be condensed / shortened. - """ - def standardized_inet(inet) when is_binary(inet) do - if String.contains?(inet, "/") do - inet - # normalize CIDR - |> CIDR.parse() - |> to_string() - else - {:ok, addr} = inet |> String.to_charlist() |> :inet.parse_address() - :inet.ntoa(addr) |> List.to_string() - end - end -end diff --git a/apps/fz_wall/lib/fz_wall/cli/helpers/sets.ex b/apps/fz_wall/lib/fz_wall/cli/helpers/sets.ex deleted file mode 100644 index 1874fe426..000000000 --- a/apps/fz_wall/lib/fz_wall/cli/helpers/sets.ex +++ /dev/null @@ -1,69 +0,0 @@ -defmodule FzWall.CLI.Helpers.Sets do - @moduledoc """ - Helper module concerning nft's named sets - """ - - @actions [:drop, :accept] - @ip_types [:ip, :ip6] - - defp port_rules_supported?, do: Application.fetch_env!(:fz_wall, :port_based_rules_supported) - - def list_filter_sets(user_id) do - get_all_filter_sets(user_id, port_rules_supported?()) - end - - defp get_all_filter_sets(user_id, false) do - get_filter_sets_spec(user_id, false) - end - - defp get_all_filter_sets(user_id, true) do - get_all_filter_sets(user_id, false) ++ get_filter_sets_spec(user_id, true) - end - - defp get_filter_sets_spec(user_id, layer4) do - cross(@ip_types, @actions) - |> Enum.map(fn {ip_type, action} -> - %{ - name: get_filter_set_name(user_id, ip_type, action, layer4), - ip_type: ip_type, - action: action, - layer4: layer4 - } - end) - end - - def list_dev_sets(user_id) do - Enum.map(@ip_types, fn type -> %{name: get_device_set_name(user_id, type), ip_type: type} end) - end - - def get_ip_types do - @ip_types - end - - def get_actions do - @actions - end - - def get_device_set_name(user_id, type), do: "user#{user_id}_#{type}_devices" - def get_user_chain(nil), do: "forward" - def get_user_chain(user_id), do: "user#{user_id}" - - def get_filter_set_name(nil, ip_type, action, false), - do: "#{ip_type}_#{action}" - - def get_filter_set_name(user_id, ip_type, action, false), - do: "user#{user_id}_#{ip_type}_#{action}" - - def get_filter_set_name(nil, ip_type, action, true), - do: "#{ip_type}_#{action}_layer4" - - def get_filter_set_name(user_id, ip_type, action, true), - do: "user#{user_id}_#{ip_type}_#{action}_layer4" - - defp cross([x | a], [y | b]) do - [{x, y}] ++ cross([x], b) ++ cross(a, [y | b]) - end - - defp cross([], _b), do: [] - defp cross(_a, []), do: [] -end diff --git a/apps/fz_wall/lib/fz_wall/cli/live.ex b/apps/fz_wall/lib/fz_wall/cli/live.ex deleted file mode 100644 index 558d31e0a..000000000 --- a/apps/fz_wall/lib/fz_wall/cli/live.ex +++ /dev/null @@ -1,167 +0,0 @@ -defmodule FzWall.CLI.Live do - @moduledoc """ - A low-level module for interacting with the nftables CLI. - - Rules operate on the nftables forward chain to deny outgoing packets to - specified IP addresses, ports, and protocols from Firezone device IPs. - """ - import FzWall.CLI.Helpers.Sets - import FzWall.CLI.Helpers.Nft - - @doc """ - Setup - """ - def setup_firewall do - teardown_table() - setup_table() - setup_chains() - setup_rules(nil) - end - - @doc """ - Adds user sets and rules. - """ - def add_user(user_id) do - add_user_set(user_id) - add_chain(get_user_chain(user_id)) - set_jump_rule(user_id) - setup_rules(user_id) - end - - defp add_user_set(user_id) do - list_dev_sets(user_id) - |> Enum.map(fn set_spec -> add_dev_set(set_spec.name, set_spec.ip_type) end) - end - - defp delete_user_set(user_id) do - list_dev_sets(user_id) - |> Enum.map(fn set_spec -> delete_set(set_spec.name) end) - end - - @doc """ - Remove user sets and rules. - """ - def delete_user(user_id) do - delete_jump_rules(user_id) - delete_user_set(user_id) - delete_chain(get_user_chain(user_id)) - delete_filter_sets(user_id) - end - - @doc """ - Adds general sets and rules. - """ - def setup_rules(user_id) do - add_filter_sets(user_id) - add_filter_rules(user_id) - end - - def set_jump_rule(user_id) do - list_dev_sets(user_id) - |> Enum.each(fn set_spec -> - insert_dev_rule(set_spec.ip_type, set_spec.name, get_user_chain(user_id)) - end) - end - - @doc """ - Adds device ip(s) to the user's sets, omitting missing IPs. - """ - def add_device(device) do - list_dev_sets(device.user_id) - |> Enum.filter(fn set_spec -> - # Only call add_elem/2 for IPs that are present - device[set_spec.ip_type] - end) - |> Enum.each(fn set_spec -> - add_elem(set_spec.name, device[set_spec.ip_type]) - end) - end - - @doc """ - Adds rule ip to its corresponding sets. - """ - def add_rule(rule) do - modify_elem(&add_elem/4, rule) - end - - @doc """ - Delete rule destination ip from its corresponding sets. - """ - def delete_rule(rule) do - modify_elem(&delete_elem/4, rule) - end - - @doc """ - Eliminates device rules from its corresponding sets. - """ - def delete_device(device) do - get_ip_types() - |> Enum.each(fn type -> remove_from_set(device.user_id, device[type], type) end) - end - - defp remove_from_set(_user_id, nil, _type), do: :no_ip - - defp remove_from_set(user_id, ip, type) do - get_device_set_name(user_id, type) - |> delete_elem(ip) - end - - defp add_filter_sets(user_id) do - list_filter_sets(user_id) - |> Enum.each(fn set_spec -> - add_filter_set(set_spec.name, set_spec.ip_type, set_spec.layer4) - end) - end - - defp delete_filter_sets(user_id) do - list_filter_sets(user_id) - |> Enum.each(fn set_spec -> delete_set(set_spec.name) end) - end - - defp add_filter_rules(user_id) do - list_filter_sets(user_id) - |> Enum.each(fn set_spec -> - insert_filter_rule( - get_user_chain(user_id), - set_spec.ip_type, - set_spec.name, - set_spec.action, - set_spec.layer4 - ) - end) - end - - defp delete_jump_rules(user_id) do - list_dev_sets(user_id) - |> Enum.each(fn set_spec -> - remove_dev_rule(set_spec.ip_type, set_spec.name, get_user_chain(user_id)) - end) - end - - # XXX: here we could add multiple devices/rules in a single nft call - def restore(%{users: users, devices: devices, rules: rules}) do - Enum.each(users, &add_user/1) - Enum.each(devices, &add_device/1) - Enum.each(rules, &add_rule/1) - end - - def proto(inet_str) do - case FzHttp.Types.INET.cast(inet_str) do - {:ok, %{address: address}} when tuple_size(address) == 4 -> :ip - {:ok, %{address: address}} when tuple_size(address) == 8 -> :ip6 - end - end - - defp modify_elem(action, rule) do - ip_type = proto(rule.destination) - port_type = rule.port_type - layer4 = port_type != nil - - action.( - get_filter_set_name(rule.user_id, ip_type, rule.action, layer4), - rule.destination, - port_type, - rule.port_range - ) - end -end diff --git a/apps/fz_wall/lib/fz_wall/cli/sandbox.ex b/apps/fz_wall/lib/fz_wall/cli/sandbox.ex deleted file mode 100644 index a7ee5670f..000000000 --- a/apps/fz_wall/lib/fz_wall/cli/sandbox.ex +++ /dev/null @@ -1,16 +0,0 @@ -defmodule FzWall.CLI.Sandbox do - @moduledoc """ - Dummy module for working with nftables. - """ - - @default_returned "" - - def setup_firewall, do: @default_returned - def add_rule(_rule_spec), do: @default_returned - def delete_rule(_rule_spec), do: @default_returned - def restore(_fz_http_rules), do: @default_returned - def add_device(_device), do: @default_returned - def delete_device(_device), do: @default_returned - def add_user(_user), do: @default_returned - def delete_user(_user), do: @default_returned -end diff --git a/apps/fz_wall/lib/fz_wall/server.ex b/apps/fz_wall/lib/fz_wall/server.ex deleted file mode 100644 index 97f0fa0e6..000000000 --- a/apps/fz_wall/lib/fz_wall/server.ex +++ /dev/null @@ -1,110 +0,0 @@ -defmodule FzWall.Server do - @moduledoc """ - Functions for applying firewall rules. - """ - use GenServer - import FzWall.CLI - - @init_timeout 1_000 - - def start_link(_) do - GenServer.start_link(__MODULE__, %{}, name: {:global, :fz_wall_server}) - end - - @impl GenServer - def init(_rules) do - cli().setup_firewall() - {:ok, settings} = GenServer.call(http_pid(), :load_settings, @init_timeout) - cli().restore(settings) - {:ok, settings} - end - - @impl GenServer - def handle_call({:add_rule, rule}, _from, %{rules: existing_rules} = state) do - new_rules = add_rule(rule, existing_rules) - - {:reply, :ok, %{state | rules: new_rules}} - end - - @impl GenServer - def handle_call({:delete_rule, rule}, _from, %{rules: existing_rules} = state) do - new_rules = delete_rule(rule, existing_rules) - - {:reply, :ok, %{state | rules: new_rules}} - end - - @impl GenServer - def handle_call({:add_device, device}, _from, %{devices: existing_devices} = state) do - new_devices = add_device(device, existing_devices) - - {:reply, :ok, %{state | devices: new_devices}} - end - - @impl GenServer - def handle_call({:delete_device, device}, _from, %{devices: existing_devices} = state) do - new_devices = delete_device(device, existing_devices) - - {:reply, :ok, %{state | devices: new_devices}} - end - - @impl GenServer - def handle_call({:set_rules, settings}, _from, _settings) do - cli().restore(settings) - - {:reply, :ok, settings} - end - - @impl GenServer - def handle_call({:add_user, user_id}, _from, %{users: existing_users} = state) do - new_users = add_user(user_id, existing_users) - - {:reply, :ok, %{state | users: new_users}} - end - - @impl GenServer - def handle_call({:delete_user, user_id}, _from, %{users: existing_users} = state) do - new_users = delete_user(user_id, existing_users) - - {:reply, :ok, %{state | users: new_users}} - end - - def http_pid do - :global.whereis_name(:fz_http_server) - end - - defp add_rule(rule, existing_rules) do - cli().add_rule(rule) - - MapSet.put(existing_rules, rule) - end - - defp delete_rule(rule, existing_rules) do - cli().delete_rule(rule) - - MapSet.delete(existing_rules, rule) - end - - defp add_user(user_id, existing_users) do - cli().add_user(user_id) - - MapSet.put(existing_users, user_id) - end - - defp delete_user(user_id, existing_users) do - cli().delete_user(user_id) - - MapSet.delete(existing_users, user_id) - end - - defp add_device(device, existing_devices) do - cli().add_device(device) - - MapSet.put(existing_devices, device) - end - - defp delete_device(device, existing_devices) do - cli().delete_device(device) - - MapSet.delete(existing_devices, device) - end -end diff --git a/apps/fz_wall/lib/fz_wall/shell.ex b/apps/fz_wall/lib/fz_wall/shell.ex deleted file mode 100644 index bd08b47ad..000000000 --- a/apps/fz_wall/lib/fz_wall/shell.ex +++ /dev/null @@ -1,38 +0,0 @@ -defmodule FzWall.Shell do - require Logger - - def bash(cmd) do - System.cmd("/bin/sh", ["-c", cmd], stderr_to_stdout: true) - end - - def exec(cmd, opts) when is_list(opts) do - case bash(cmd) do - {result, 0} -> - result - - {error, exit_code} -> - error_msg = """ - Error executing command #{cmd}. - Exit code: #{exit_code} - Error message: - #{error} - """ - - if opts[:suppress] do - Logger.warn(error_msg) - else - raise error_msg - end - - error_msg - end - end - - def exec(cmd) do - exec(cmd, suppress: true) - end - - def exec!(cmd) do - exec(cmd, suppress: false) - end -end diff --git a/apps/fz_wall/mix.exs b/apps/fz_wall/mix.exs deleted file mode 100644 index 9dc91c9af..000000000 --- a/apps/fz_wall/mix.exs +++ /dev/null @@ -1,46 +0,0 @@ -defmodule FzWall.MixProject do - use Mix.Project - - def version do - # Use dummy version for dev and test - System.get_env("VERSION", "0.0.0+git.0.deadbeef") - end - - def project do - [ - app: :fz_wall, - version: version(), - build_path: "../../_build", - config_path: "../../config/config.exs", - deps_path: "../../deps", - lockfile: "../../mix.lock", - elixir: "~> 1.12", - start_permanent: Mix.env() == :prod, - test_coverage: [tool: ExCoveralls], - preferred_cli_env: [ - coveralls: :test, - "coveralls.detail": :test, - "coveralls.post": :test, - "coveralls.html": :test - ], - deps: deps() - ] - end - - # Run "mix help compile.app" to learn about applications. - def application do - [ - extra_applications: [:logger], - mod: {FzWall.Application, []}, - registered: [:fz_wall_server] - ] - end - - # Run "mix help deps" to learn about dependencies. - defp deps do - [ - {:fz_http, in_umbrella: true}, - {:cidr, github: "firezone/cidr-elixir"} - ] - end -end diff --git a/apps/fz_wall/test/cli/helpers/nft_test.exs b/apps/fz_wall/test/cli/helpers/nft_test.exs deleted file mode 100644 index 1ca5c3c77..000000000 --- a/apps/fz_wall/test/cli/helpers/nft_test.exs +++ /dev/null @@ -1,18 +0,0 @@ -defmodule FzWall.CLI.Helpers.NftTest do - use ExUnit.Case, async: true - import FzWall.CLI.Helpers.Nft - - describe "standardized_inet/1" do - test "sanitizes CIDRs with invalid start" do - assert "10.0.0.0/24" == standardized_inet("10.0.0.5/24") - end - - test "formats CIDRs" do - assert "::/0" == standardized_inet("::0/0") - end - - test "formats IP address" do - assert "fd00:3::1" == standardized_inet("fd00:3:0000::1") - end - end -end diff --git a/apps/fz_wall/test/cli/live_test.exs b/apps/fz_wall/test/cli/live_test.exs deleted file mode 100644 index e12849f0e..000000000 --- a/apps/fz_wall/test/cli/live_test.exs +++ /dev/null @@ -1,23 +0,0 @@ -defmodule FzWall.CLI.LiveTest do - use ExUnit.Case - - describe "proto/1" do - import FzWall.CLI.Live, only: [proto: 1] - - test "handles ipv4 addresses" do - assert proto("100.64.0.1") == :ip - end - - test "handles ipv6 addresses" do - assert proto("fd00::1") == :ip6 - end - - test "handles ipv4 cidrs" do - assert proto("100.64.0.0/10") == :ip - end - - test "handles ipv6 cidrs" do - assert proto("fd00::/106") == :ip6 - end - end -end diff --git a/apps/fz_wall/test/fz_wall_test.exs b/apps/fz_wall/test/fz_wall_test.exs deleted file mode 100644 index c74786de1..000000000 --- a/apps/fz_wall/test/fz_wall_test.exs +++ /dev/null @@ -1,4 +0,0 @@ -defmodule FzWallTest do - use ExUnit.Case - doctest FzWall -end diff --git a/apps/fz_wall/test/test_helper.exs b/apps/fz_wall/test/test_helper.exs deleted file mode 100644 index 869559e70..000000000 --- a/apps/fz_wall/test/test_helper.exs +++ /dev/null @@ -1 +0,0 @@ -ExUnit.start() diff --git a/apps/fz_http/.formatter.exs b/apps/web/.formatter.exs similarity index 100% rename from apps/fz_http/.formatter.exs rename to apps/web/.formatter.exs diff --git a/apps/fz_http/.gitignore b/apps/web/.gitignore similarity index 100% rename from apps/fz_http/.gitignore rename to apps/web/.gitignore diff --git a/apps/fz_http/README.md b/apps/web/README.md similarity index 100% rename from apps/fz_http/README.md rename to apps/web/README.md diff --git a/apps/fz_http/assets/.babelrc b/apps/web/assets/.babelrc similarity index 100% rename from apps/fz_http/assets/.babelrc rename to apps/web/assets/.babelrc diff --git a/apps/fz_http/assets/config.dev.js b/apps/web/assets/config.dev.js similarity index 100% rename from apps/fz_http/assets/config.dev.js rename to apps/web/assets/config.dev.js diff --git a/apps/fz_http/assets/config.prod.js b/apps/web/assets/config.prod.js similarity index 100% rename from apps/fz_http/assets/config.prod.js rename to apps/web/assets/config.prod.js diff --git a/apps/fz_http/assets/css/app.scss b/apps/web/assets/css/app.scss similarity index 100% rename from apps/fz_http/assets/css/app.scss rename to apps/web/assets/css/app.scss diff --git a/apps/fz_http/assets/css/email.scss b/apps/web/assets/css/email.scss similarity index 100% rename from apps/fz_http/assets/css/email.scss rename to apps/web/assets/css/email.scss diff --git a/apps/fz_http/assets/css/main.scss b/apps/web/assets/css/main.scss similarity index 100% rename from apps/fz_http/assets/css/main.scss rename to apps/web/assets/css/main.scss diff --git a/apps/fz_http/assets/css/tables.scss b/apps/web/assets/css/tables.scss similarity index 100% rename from apps/fz_http/assets/css/tables.scss rename to apps/web/assets/css/tables.scss diff --git a/apps/fz_http/assets/esbuild.js b/apps/web/assets/esbuild.js similarity index 100% rename from apps/fz_http/assets/esbuild.js rename to apps/web/assets/esbuild.js diff --git a/apps/fz_http/assets/js/admin.js b/apps/web/assets/js/admin.js similarity index 100% rename from apps/fz_http/assets/js/admin.js rename to apps/web/assets/js/admin.js diff --git a/apps/fz_http/assets/js/crypto.js b/apps/web/assets/js/crypto.js similarity index 100% rename from apps/fz_http/assets/js/crypto.js rename to apps/web/assets/js/crypto.js diff --git a/apps/fz_http/assets/js/event_listeners.js b/apps/web/assets/js/event_listeners.js similarity index 100% rename from apps/fz_http/assets/js/event_listeners.js rename to apps/web/assets/js/event_listeners.js diff --git a/apps/fz_http/assets/js/hooks.js b/apps/web/assets/js/hooks.js similarity index 100% rename from apps/fz_http/assets/js/hooks.js rename to apps/web/assets/js/hooks.js diff --git a/apps/fz_http/assets/js/live_view.js b/apps/web/assets/js/live_view.js similarity index 100% rename from apps/fz_http/assets/js/live_view.js rename to apps/web/assets/js/live_view.js diff --git a/apps/fz_http/assets/js/qrcode.js b/apps/web/assets/js/qrcode.js similarity index 100% rename from apps/fz_http/assets/js/qrcode.js rename to apps/web/assets/js/qrcode.js diff --git a/apps/fz_http/assets/js/root.js b/apps/web/assets/js/root.js similarity index 100% rename from apps/fz_http/assets/js/root.js rename to apps/web/assets/js/root.js diff --git a/apps/fz_http/assets/js/unprivileged.js b/apps/web/assets/js/unprivileged.js similarity index 100% rename from apps/fz_http/assets/js/unprivileged.js rename to apps/web/assets/js/unprivileged.js diff --git a/apps/fz_http/assets/js/util.js b/apps/web/assets/js/util.js similarity index 100% rename from apps/fz_http/assets/js/util.js rename to apps/web/assets/js/util.js diff --git a/apps/fz_http/assets/js/wg_conf.js b/apps/web/assets/js/wg_conf.js similarity index 100% rename from apps/fz_http/assets/js/wg_conf.js rename to apps/web/assets/js/wg_conf.js diff --git a/apps/fz_http/assets/local_modules/admin-one-bulma-dashboard/.editorconfig b/apps/web/assets/local_modules/admin-one-bulma-dashboard/.editorconfig similarity index 100% rename from apps/fz_http/assets/local_modules/admin-one-bulma-dashboard/.editorconfig rename to apps/web/assets/local_modules/admin-one-bulma-dashboard/.editorconfig diff --git a/apps/fz_http/assets/local_modules/admin-one-bulma-dashboard/.gitattributes b/apps/web/assets/local_modules/admin-one-bulma-dashboard/.gitattributes similarity index 100% rename from apps/fz_http/assets/local_modules/admin-one-bulma-dashboard/.gitattributes rename to apps/web/assets/local_modules/admin-one-bulma-dashboard/.gitattributes diff --git a/apps/fz_http/assets/local_modules/admin-one-bulma-dashboard/.gitignore b/apps/web/assets/local_modules/admin-one-bulma-dashboard/.gitignore similarity index 100% rename from apps/fz_http/assets/local_modules/admin-one-bulma-dashboard/.gitignore rename to apps/web/assets/local_modules/admin-one-bulma-dashboard/.gitignore diff --git a/apps/fz_http/assets/local_modules/admin-one-bulma-dashboard/.tool-versions b/apps/web/assets/local_modules/admin-one-bulma-dashboard/.tool-versions similarity index 100% rename from apps/fz_http/assets/local_modules/admin-one-bulma-dashboard/.tool-versions rename to apps/web/assets/local_modules/admin-one-bulma-dashboard/.tool-versions diff --git a/apps/fz_http/assets/local_modules/admin-one-bulma-dashboard/LICENSE b/apps/web/assets/local_modules/admin-one-bulma-dashboard/LICENSE similarity index 100% rename from apps/fz_http/assets/local_modules/admin-one-bulma-dashboard/LICENSE rename to apps/web/assets/local_modules/admin-one-bulma-dashboard/LICENSE diff --git a/apps/fz_http/assets/local_modules/admin-one-bulma-dashboard/README.md b/apps/web/assets/local_modules/admin-one-bulma-dashboard/README.md similarity index 100% rename from apps/fz_http/assets/local_modules/admin-one-bulma-dashboard/README.md rename to apps/web/assets/local_modules/admin-one-bulma-dashboard/README.md diff --git a/apps/fz_http/assets/local_modules/admin-one-bulma-dashboard/package.json b/apps/web/assets/local_modules/admin-one-bulma-dashboard/package.json similarity index 100% rename from apps/fz_http/assets/local_modules/admin-one-bulma-dashboard/package.json rename to apps/web/assets/local_modules/admin-one-bulma-dashboard/package.json diff --git a/apps/fz_http/assets/local_modules/admin-one-bulma-dashboard/src/js/main.js b/apps/web/assets/local_modules/admin-one-bulma-dashboard/src/js/main.js similarity index 100% rename from apps/fz_http/assets/local_modules/admin-one-bulma-dashboard/src/js/main.js rename to apps/web/assets/local_modules/admin-one-bulma-dashboard/src/js/main.js diff --git a/apps/fz_http/assets/local_modules/admin-one-bulma-dashboard/src/scss/_aside.scss b/apps/web/assets/local_modules/admin-one-bulma-dashboard/src/scss/_aside.scss similarity index 100% rename from apps/fz_http/assets/local_modules/admin-one-bulma-dashboard/src/scss/_aside.scss rename to apps/web/assets/local_modules/admin-one-bulma-dashboard/src/scss/_aside.scss diff --git a/apps/fz_http/assets/local_modules/admin-one-bulma-dashboard/src/scss/_card.scss b/apps/web/assets/local_modules/admin-one-bulma-dashboard/src/scss/_card.scss similarity index 100% rename from apps/fz_http/assets/local_modules/admin-one-bulma-dashboard/src/scss/_card.scss rename to apps/web/assets/local_modules/admin-one-bulma-dashboard/src/scss/_card.scss diff --git a/apps/fz_http/assets/local_modules/admin-one-bulma-dashboard/src/scss/_footer.scss b/apps/web/assets/local_modules/admin-one-bulma-dashboard/src/scss/_footer.scss similarity index 100% rename from apps/fz_http/assets/local_modules/admin-one-bulma-dashboard/src/scss/_footer.scss rename to apps/web/assets/local_modules/admin-one-bulma-dashboard/src/scss/_footer.scss diff --git a/apps/fz_http/assets/local_modules/admin-one-bulma-dashboard/src/scss/_form.scss b/apps/web/assets/local_modules/admin-one-bulma-dashboard/src/scss/_form.scss similarity index 100% rename from apps/fz_http/assets/local_modules/admin-one-bulma-dashboard/src/scss/_form.scss rename to apps/web/assets/local_modules/admin-one-bulma-dashboard/src/scss/_form.scss diff --git a/apps/fz_http/assets/local_modules/admin-one-bulma-dashboard/src/scss/_hero-bar.scss b/apps/web/assets/local_modules/admin-one-bulma-dashboard/src/scss/_hero-bar.scss similarity index 100% rename from apps/fz_http/assets/local_modules/admin-one-bulma-dashboard/src/scss/_hero-bar.scss rename to apps/web/assets/local_modules/admin-one-bulma-dashboard/src/scss/_hero-bar.scss diff --git a/apps/fz_http/assets/local_modules/admin-one-bulma-dashboard/src/scss/_main-section.scss b/apps/web/assets/local_modules/admin-one-bulma-dashboard/src/scss/_main-section.scss similarity index 100% rename from apps/fz_http/assets/local_modules/admin-one-bulma-dashboard/src/scss/_main-section.scss rename to apps/web/assets/local_modules/admin-one-bulma-dashboard/src/scss/_main-section.scss diff --git a/apps/fz_http/assets/local_modules/admin-one-bulma-dashboard/src/scss/_misc.scss b/apps/web/assets/local_modules/admin-one-bulma-dashboard/src/scss/_misc.scss similarity index 100% rename from apps/fz_http/assets/local_modules/admin-one-bulma-dashboard/src/scss/_misc.scss rename to apps/web/assets/local_modules/admin-one-bulma-dashboard/src/scss/_misc.scss diff --git a/apps/fz_http/assets/local_modules/admin-one-bulma-dashboard/src/scss/_mixins.scss b/apps/web/assets/local_modules/admin-one-bulma-dashboard/src/scss/_mixins.scss similarity index 100% rename from apps/fz_http/assets/local_modules/admin-one-bulma-dashboard/src/scss/_mixins.scss rename to apps/web/assets/local_modules/admin-one-bulma-dashboard/src/scss/_mixins.scss diff --git a/apps/fz_http/assets/local_modules/admin-one-bulma-dashboard/src/scss/_modal.scss b/apps/web/assets/local_modules/admin-one-bulma-dashboard/src/scss/_modal.scss similarity index 100% rename from apps/fz_http/assets/local_modules/admin-one-bulma-dashboard/src/scss/_modal.scss rename to apps/web/assets/local_modules/admin-one-bulma-dashboard/src/scss/_modal.scss diff --git a/apps/fz_http/assets/local_modules/admin-one-bulma-dashboard/src/scss/_nav-bar.scss b/apps/web/assets/local_modules/admin-one-bulma-dashboard/src/scss/_nav-bar.scss similarity index 100% rename from apps/fz_http/assets/local_modules/admin-one-bulma-dashboard/src/scss/_nav-bar.scss rename to apps/web/assets/local_modules/admin-one-bulma-dashboard/src/scss/_nav-bar.scss diff --git a/apps/fz_http/assets/local_modules/admin-one-bulma-dashboard/src/scss/_table.scss b/apps/web/assets/local_modules/admin-one-bulma-dashboard/src/scss/_table.scss similarity index 100% rename from apps/fz_http/assets/local_modules/admin-one-bulma-dashboard/src/scss/_table.scss rename to apps/web/assets/local_modules/admin-one-bulma-dashboard/src/scss/_table.scss diff --git a/apps/fz_http/assets/local_modules/admin-one-bulma-dashboard/src/scss/_theme-firezone.scss b/apps/web/assets/local_modules/admin-one-bulma-dashboard/src/scss/_theme-firezone.scss similarity index 100% rename from apps/fz_http/assets/local_modules/admin-one-bulma-dashboard/src/scss/_theme-firezone.scss rename to apps/web/assets/local_modules/admin-one-bulma-dashboard/src/scss/_theme-firezone.scss diff --git a/apps/fz_http/assets/local_modules/admin-one-bulma-dashboard/src/scss/_tiles.scss b/apps/web/assets/local_modules/admin-one-bulma-dashboard/src/scss/_tiles.scss similarity index 100% rename from apps/fz_http/assets/local_modules/admin-one-bulma-dashboard/src/scss/_tiles.scss rename to apps/web/assets/local_modules/admin-one-bulma-dashboard/src/scss/_tiles.scss diff --git a/apps/fz_http/assets/local_modules/admin-one-bulma-dashboard/src/scss/_title-bar.scss b/apps/web/assets/local_modules/admin-one-bulma-dashboard/src/scss/_title-bar.scss similarity index 100% rename from apps/fz_http/assets/local_modules/admin-one-bulma-dashboard/src/scss/_title-bar.scss rename to apps/web/assets/local_modules/admin-one-bulma-dashboard/src/scss/_title-bar.scss diff --git a/apps/fz_http/assets/local_modules/admin-one-bulma-dashboard/src/scss/libs/_all.scss b/apps/web/assets/local_modules/admin-one-bulma-dashboard/src/scss/libs/_all.scss similarity index 100% rename from apps/fz_http/assets/local_modules/admin-one-bulma-dashboard/src/scss/libs/_all.scss rename to apps/web/assets/local_modules/admin-one-bulma-dashboard/src/scss/libs/_all.scss diff --git a/apps/fz_http/assets/local_modules/admin-one-bulma-dashboard/src/scss/main.scss b/apps/web/assets/local_modules/admin-one-bulma-dashboard/src/scss/main.scss similarity index 100% rename from apps/fz_http/assets/local_modules/admin-one-bulma-dashboard/src/scss/main.scss rename to apps/web/assets/local_modules/admin-one-bulma-dashboard/src/scss/main.scss diff --git a/apps/fz_http/assets/package.json b/apps/web/assets/package.json similarity index 100% rename from apps/fz_http/assets/package.json rename to apps/web/assets/package.json diff --git a/apps/fz_http/assets/postcss.config.js b/apps/web/assets/postcss.config.js similarity index 100% rename from apps/fz_http/assets/postcss.config.js rename to apps/web/assets/postcss.config.js diff --git a/apps/fz_http/assets/yarn.lock b/apps/web/assets/yarn.lock similarity index 100% rename from apps/fz_http/assets/yarn.lock rename to apps/web/assets/yarn.lock diff --git a/apps/fz_http/coveralls.json b/apps/web/coveralls.json similarity index 100% rename from apps/fz_http/coveralls.json rename to apps/web/coveralls.json diff --git a/apps/fz_http/lib/fz_http_web.ex b/apps/web/lib/fz_http_web.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web.ex rename to apps/web/lib/fz_http_web.ex diff --git a/apps/fz_http/lib/fz_http_web/auth/html/authentication.ex b/apps/web/lib/fz_http_web/auth/html/authentication.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/auth/html/authentication.ex rename to apps/web/lib/fz_http_web/auth/html/authentication.ex diff --git a/apps/fz_http/lib/fz_http_web/auth/html/error_handler.ex b/apps/web/lib/fz_http_web/auth/html/error_handler.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/auth/html/error_handler.ex rename to apps/web/lib/fz_http_web/auth/html/error_handler.ex diff --git a/apps/fz_http/lib/fz_http_web/auth/html/pipeline.ex b/apps/web/lib/fz_http_web/auth/html/pipeline.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/auth/html/pipeline.ex rename to apps/web/lib/fz_http_web/auth/html/pipeline.ex diff --git a/apps/fz_http/lib/fz_http_web/auth/json/authentication.ex b/apps/web/lib/fz_http_web/auth/json/authentication.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/auth/json/authentication.ex rename to apps/web/lib/fz_http_web/auth/json/authentication.ex diff --git a/apps/fz_http/lib/fz_http_web/auth/json/error_handler.ex b/apps/web/lib/fz_http_web/auth/json/error_handler.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/auth/json/error_handler.ex rename to apps/web/lib/fz_http_web/auth/json/error_handler.ex diff --git a/apps/fz_http/lib/fz_http_web/auth/json/pipeline.ex b/apps/web/lib/fz_http_web/auth/json/pipeline.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/auth/json/pipeline.ex rename to apps/web/lib/fz_http_web/auth/json/pipeline.ex diff --git a/apps/fz_http/lib/fz_http_web/authorization_helpers.ex b/apps/web/lib/fz_http_web/authorization_helpers.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/authorization_helpers.ex rename to apps/web/lib/fz_http_web/authorization_helpers.ex diff --git a/apps/fz_http/lib/fz_http_web/channels/notification_channel.ex b/apps/web/lib/fz_http_web/channels/notification_channel.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/channels/notification_channel.ex rename to apps/web/lib/fz_http_web/channels/notification_channel.ex diff --git a/apps/fz_http/lib/fz_http_web/controller_helpers.ex b/apps/web/lib/fz_http_web/controller_helpers.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/controller_helpers.ex rename to apps/web/lib/fz_http_web/controller_helpers.ex diff --git a/apps/fz_http/lib/fz_http_web/controllers/auth_controller.ex b/apps/web/lib/fz_http_web/controllers/auth_controller.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/controllers/auth_controller.ex rename to apps/web/lib/fz_http_web/controllers/auth_controller.ex diff --git a/apps/fz_http/lib/fz_http_web/controllers/browser_controller.ex b/apps/web/lib/fz_http_web/controllers/browser_controller.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/controllers/browser_controller.ex rename to apps/web/lib/fz_http_web/controllers/browser_controller.ex diff --git a/apps/fz_http/lib/fz_http_web/controllers/debug_controller.ex b/apps/web/lib/fz_http_web/controllers/debug_controller.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/controllers/debug_controller.ex rename to apps/web/lib/fz_http_web/controllers/debug_controller.ex diff --git a/apps/fz_http/lib/fz_http_web/controllers/json/configuration_controller.ex b/apps/web/lib/fz_http_web/controllers/json/configuration_controller.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/controllers/json/configuration_controller.ex rename to apps/web/lib/fz_http_web/controllers/json/configuration_controller.ex diff --git a/apps/fz_http/lib/fz_http_web/controllers/json/device_controller.ex b/apps/web/lib/fz_http_web/controllers/json/device_controller.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/controllers/json/device_controller.ex rename to apps/web/lib/fz_http_web/controllers/json/device_controller.ex diff --git a/apps/fz_http/lib/fz_http_web/controllers/json/fallback_controller.ex b/apps/web/lib/fz_http_web/controllers/json/fallback_controller.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/controllers/json/fallback_controller.ex rename to apps/web/lib/fz_http_web/controllers/json/fallback_controller.ex diff --git a/apps/fz_http/lib/fz_http_web/controllers/json/rule_controller.ex b/apps/web/lib/fz_http_web/controllers/json/rule_controller.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/controllers/json/rule_controller.ex rename to apps/web/lib/fz_http_web/controllers/json/rule_controller.ex diff --git a/apps/fz_http/lib/fz_http_web/controllers/json/user_controller.ex b/apps/web/lib/fz_http_web/controllers/json/user_controller.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/controllers/json/user_controller.ex rename to apps/web/lib/fz_http_web/controllers/json/user_controller.ex diff --git a/apps/fz_http/lib/fz_http_web/controllers/root_controller.ex b/apps/web/lib/fz_http_web/controllers/root_controller.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/controllers/root_controller.ex rename to apps/web/lib/fz_http_web/controllers/root_controller.ex diff --git a/apps/fz_http/lib/fz_http_web/controllers/user_controller.ex b/apps/web/lib/fz_http_web/controllers/user_controller.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/controllers/user_controller.ex rename to apps/web/lib/fz_http_web/controllers/user_controller.ex diff --git a/apps/fz_http/lib/fz_http_web/doc_helpers.ex b/apps/web/lib/fz_http_web/doc_helpers.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/doc_helpers.ex rename to apps/web/lib/fz_http_web/doc_helpers.ex diff --git a/apps/fz_http/lib/fz_http_web/endpoint.ex b/apps/web/lib/fz_http_web/endpoint.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/endpoint.ex rename to apps/web/lib/fz_http_web/endpoint.ex diff --git a/apps/fz_http/lib/fz_http_web/error_helpers.ex b/apps/web/lib/fz_http_web/error_helpers.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/error_helpers.ex rename to apps/web/lib/fz_http_web/error_helpers.ex diff --git a/apps/fz_http/lib/fz_http_web/gettext.ex b/apps/web/lib/fz_http_web/gettext.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/gettext.ex rename to apps/web/lib/fz_http_web/gettext.ex diff --git a/apps/fz_http/lib/fz_http_web/header_helpers.ex b/apps/web/lib/fz_http_web/header_helpers.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/header_helpers.ex rename to apps/web/lib/fz_http_web/header_helpers.ex diff --git a/apps/fz_http/lib/fz_http_web/live/connectivity_check_live/index.html.heex b/apps/web/lib/fz_http_web/live/connectivity_check_live/index.html.heex similarity index 100% rename from apps/fz_http/lib/fz_http_web/live/connectivity_check_live/index.html.heex rename to apps/web/lib/fz_http_web/live/connectivity_check_live/index.html.heex diff --git a/apps/fz_http/lib/fz_http_web/live/connectivity_check_live/index_live.ex b/apps/web/lib/fz_http_web/live/connectivity_check_live/index_live.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/live/connectivity_check_live/index_live.ex rename to apps/web/lib/fz_http_web/live/connectivity_check_live/index_live.ex diff --git a/apps/fz_http/lib/fz_http_web/live/device_live/admin/index.html.heex b/apps/web/lib/fz_http_web/live/device_live/admin/index.html.heex similarity index 100% rename from apps/fz_http/lib/fz_http_web/live/device_live/admin/index.html.heex rename to apps/web/lib/fz_http_web/live/device_live/admin/index.html.heex diff --git a/apps/fz_http/lib/fz_http_web/live/device_live/admin/index_live.ex b/apps/web/lib/fz_http_web/live/device_live/admin/index_live.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/live/device_live/admin/index_live.ex rename to apps/web/lib/fz_http_web/live/device_live/admin/index_live.ex diff --git a/apps/fz_http/lib/fz_http_web/live/device_live/admin/show.html.heex b/apps/web/lib/fz_http_web/live/device_live/admin/show.html.heex similarity index 100% rename from apps/fz_http/lib/fz_http_web/live/device_live/admin/show.html.heex rename to apps/web/lib/fz_http_web/live/device_live/admin/show.html.heex diff --git a/apps/fz_http/lib/fz_http_web/live/device_live/admin/show_live.ex b/apps/web/lib/fz_http_web/live/device_live/admin/show_live.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/live/device_live/admin/show_live.ex rename to apps/web/lib/fz_http_web/live/device_live/admin/show_live.ex diff --git a/apps/fz_http/lib/fz_http_web/live/device_live/new_form_component.ex b/apps/web/lib/fz_http_web/live/device_live/new_form_component.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/live/device_live/new_form_component.ex rename to apps/web/lib/fz_http_web/live/device_live/new_form_component.ex diff --git a/apps/fz_http/lib/fz_http_web/live/device_live/new_form_component.html.heex b/apps/web/lib/fz_http_web/live/device_live/new_form_component.html.heex similarity index 100% rename from apps/fz_http/lib/fz_http_web/live/device_live/new_form_component.html.heex rename to apps/web/lib/fz_http_web/live/device_live/new_form_component.html.heex diff --git a/apps/fz_http/lib/fz_http_web/live/device_live/unprivileged/index.html.heex b/apps/web/lib/fz_http_web/live/device_live/unprivileged/index.html.heex similarity index 100% rename from apps/fz_http/lib/fz_http_web/live/device_live/unprivileged/index.html.heex rename to apps/web/lib/fz_http_web/live/device_live/unprivileged/index.html.heex diff --git a/apps/fz_http/lib/fz_http_web/live/device_live/unprivileged/index_live.ex b/apps/web/lib/fz_http_web/live/device_live/unprivileged/index_live.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/live/device_live/unprivileged/index_live.ex rename to apps/web/lib/fz_http_web/live/device_live/unprivileged/index_live.ex diff --git a/apps/fz_http/lib/fz_http_web/live/device_live/unprivileged/show.html.heex b/apps/web/lib/fz_http_web/live/device_live/unprivileged/show.html.heex similarity index 100% rename from apps/fz_http/lib/fz_http_web/live/device_live/unprivileged/show.html.heex rename to apps/web/lib/fz_http_web/live/device_live/unprivileged/show.html.heex diff --git a/apps/fz_http/lib/fz_http_web/live/device_live/unprivileged/show_live.ex b/apps/web/lib/fz_http_web/live/device_live/unprivileged/show_live.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/live/device_live/unprivileged/show_live.ex rename to apps/web/lib/fz_http_web/live/device_live/unprivileged/show_live.ex diff --git a/apps/fz_http/lib/fz_http_web/live/hooks/allow_ecto_sandbox.ex b/apps/web/lib/fz_http_web/live/hooks/allow_ecto_sandbox.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/live/hooks/allow_ecto_sandbox.ex rename to apps/web/lib/fz_http_web/live/hooks/allow_ecto_sandbox.ex diff --git a/apps/fz_http/lib/fz_http_web/live/hooks/live_auth.ex b/apps/web/lib/fz_http_web/live/hooks/live_auth.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/live/hooks/live_auth.ex rename to apps/web/lib/fz_http_web/live/hooks/live_auth.ex diff --git a/apps/fz_http/lib/fz_http_web/live/hooks/live_mfa.ex b/apps/web/lib/fz_http_web/live/hooks/live_mfa.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/live/hooks/live_mfa.ex rename to apps/web/lib/fz_http_web/live/hooks/live_mfa.ex diff --git a/apps/fz_http/lib/fz_http_web/live/hooks/live_nav.ex b/apps/web/lib/fz_http_web/live/hooks/live_nav.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/live/hooks/live_nav.ex rename to apps/web/lib/fz_http_web/live/hooks/live_nav.ex diff --git a/apps/fz_http/lib/fz_http_web/live/logo_component.ex b/apps/web/lib/fz_http_web/live/logo_component.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/live/logo_component.ex rename to apps/web/lib/fz_http_web/live/logo_component.ex diff --git a/apps/fz_http/lib/fz_http_web/live/mfa_live/auth_live.ex b/apps/web/lib/fz_http_web/live/mfa_live/auth_live.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/live/mfa_live/auth_live.ex rename to apps/web/lib/fz_http_web/live/mfa_live/auth_live.ex diff --git a/apps/fz_http/lib/fz_http_web/live/mfa_live/register_component.ex b/apps/web/lib/fz_http_web/live/mfa_live/register_component.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/live/mfa_live/register_component.ex rename to apps/web/lib/fz_http_web/live/mfa_live/register_component.ex diff --git a/apps/fz_http/lib/fz_http_web/live/mfa_live/register_steps_component.ex b/apps/web/lib/fz_http_web/live/mfa_live/register_steps_component.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/live/mfa_live/register_steps_component.ex rename to apps/web/lib/fz_http_web/live/mfa_live/register_steps_component.ex diff --git a/apps/fz_http/lib/fz_http_web/live/modal_component.ex b/apps/web/lib/fz_http_web/live/modal_component.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/live/modal_component.ex rename to apps/web/lib/fz_http_web/live/modal_component.ex diff --git a/apps/fz_http/lib/fz_http_web/live/notifications_live/badge.ex b/apps/web/lib/fz_http_web/live/notifications_live/badge.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/live/notifications_live/badge.ex rename to apps/web/lib/fz_http_web/live/notifications_live/badge.ex diff --git a/apps/fz_http/lib/fz_http_web/live/notifications_live/badge.html.heex b/apps/web/lib/fz_http_web/live/notifications_live/badge.html.heex similarity index 100% rename from apps/fz_http/lib/fz_http_web/live/notifications_live/badge.html.heex rename to apps/web/lib/fz_http_web/live/notifications_live/badge.html.heex diff --git a/apps/fz_http/lib/fz_http_web/live/notifications_live/index.html.heex b/apps/web/lib/fz_http_web/live/notifications_live/index.html.heex similarity index 100% rename from apps/fz_http/lib/fz_http_web/live/notifications_live/index.html.heex rename to apps/web/lib/fz_http_web/live/notifications_live/index.html.heex diff --git a/apps/fz_http/lib/fz_http_web/live/notifications_live/index_live.ex b/apps/web/lib/fz_http_web/live/notifications_live/index_live.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/live/notifications_live/index_live.ex rename to apps/web/lib/fz_http_web/live/notifications_live/index_live.ex diff --git a/apps/fz_http/lib/fz_http_web/live/oidc_live/connections_table_component.ex b/apps/web/lib/fz_http_web/live/oidc_live/connections_table_component.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/live/oidc_live/connections_table_component.ex rename to apps/web/lib/fz_http_web/live/oidc_live/connections_table_component.ex diff --git a/apps/fz_http/lib/fz_http_web/live/oidc_live/connections_table_component.html.heex b/apps/web/lib/fz_http_web/live/oidc_live/connections_table_component.html.heex similarity index 100% rename from apps/fz_http/lib/fz_http_web/live/oidc_live/connections_table_component.html.heex rename to apps/web/lib/fz_http_web/live/oidc_live/connections_table_component.html.heex diff --git a/apps/fz_http/lib/fz_http_web/live/rule_live/index.html.heex b/apps/web/lib/fz_http_web/live/rule_live/index.html.heex similarity index 100% rename from apps/fz_http/lib/fz_http_web/live/rule_live/index.html.heex rename to apps/web/lib/fz_http_web/live/rule_live/index.html.heex diff --git a/apps/fz_http/lib/fz_http_web/live/rule_live/index_live.ex b/apps/web/lib/fz_http_web/live/rule_live/index_live.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/live/rule_live/index_live.ex rename to apps/web/lib/fz_http_web/live/rule_live/index_live.ex diff --git a/apps/fz_http/lib/fz_http_web/live/rule_live/rule_list_component.ex b/apps/web/lib/fz_http_web/live/rule_live/rule_list_component.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/live/rule_live/rule_list_component.ex rename to apps/web/lib/fz_http_web/live/rule_live/rule_list_component.ex diff --git a/apps/fz_http/lib/fz_http_web/live/rule_live/rule_list_component.html.heex b/apps/web/lib/fz_http_web/live/rule_live/rule_list_component.html.heex similarity index 100% rename from apps/fz_http/lib/fz_http_web/live/rule_live/rule_list_component.html.heex rename to apps/web/lib/fz_http_web/live/rule_live/rule_list_component.html.heex diff --git a/apps/fz_http/lib/fz_http_web/live/setting_live/account.html.heex b/apps/web/lib/fz_http_web/live/setting_live/account.html.heex similarity index 100% rename from apps/fz_http/lib/fz_http_web/live/setting_live/account.html.heex rename to apps/web/lib/fz_http_web/live/setting_live/account.html.heex diff --git a/apps/fz_http/lib/fz_http_web/live/setting_live/account_form_component.ex b/apps/web/lib/fz_http_web/live/setting_live/account_form_component.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/live/setting_live/account_form_component.ex rename to apps/web/lib/fz_http_web/live/setting_live/account_form_component.ex diff --git a/apps/fz_http/lib/fz_http_web/live/setting_live/account_form_component.html.heex b/apps/web/lib/fz_http_web/live/setting_live/account_form_component.html.heex similarity index 100% rename from apps/fz_http/lib/fz_http_web/live/setting_live/account_form_component.html.heex rename to apps/web/lib/fz_http_web/live/setting_live/account_form_component.html.heex diff --git a/apps/fz_http/lib/fz_http_web/live/setting_live/account_live.ex b/apps/web/lib/fz_http_web/live/setting_live/account_live.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/live/setting_live/account_live.ex rename to apps/web/lib/fz_http_web/live/setting_live/account_live.ex diff --git a/apps/fz_http/lib/fz_http_web/live/setting_live/client_defaults.html.heex b/apps/web/lib/fz_http_web/live/setting_live/client_defaults.html.heex similarity index 100% rename from apps/fz_http/lib/fz_http_web/live/setting_live/client_defaults.html.heex rename to apps/web/lib/fz_http_web/live/setting_live/client_defaults.html.heex diff --git a/apps/fz_http/lib/fz_http_web/live/setting_live/client_defaults_form_component.ex b/apps/web/lib/fz_http_web/live/setting_live/client_defaults_form_component.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/live/setting_live/client_defaults_form_component.ex rename to apps/web/lib/fz_http_web/live/setting_live/client_defaults_form_component.ex diff --git a/apps/fz_http/lib/fz_http_web/live/setting_live/client_defaults_form_component.html.heex b/apps/web/lib/fz_http_web/live/setting_live/client_defaults_form_component.html.heex similarity index 100% rename from apps/fz_http/lib/fz_http_web/live/setting_live/client_defaults_form_component.html.heex rename to apps/web/lib/fz_http_web/live/setting_live/client_defaults_form_component.html.heex diff --git a/apps/fz_http/lib/fz_http_web/live/setting_live/client_defaults_live.ex b/apps/web/lib/fz_http_web/live/setting_live/client_defaults_live.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/live/setting_live/client_defaults_live.ex rename to apps/web/lib/fz_http_web/live/setting_live/client_defaults_live.ex diff --git a/apps/fz_http/lib/fz_http_web/live/setting_live/customization.html.heex b/apps/web/lib/fz_http_web/live/setting_live/customization.html.heex similarity index 100% rename from apps/fz_http/lib/fz_http_web/live/setting_live/customization.html.heex rename to apps/web/lib/fz_http_web/live/setting_live/customization.html.heex diff --git a/apps/fz_http/lib/fz_http_web/live/setting_live/customization_live.ex b/apps/web/lib/fz_http_web/live/setting_live/customization_live.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/live/setting_live/customization_live.ex rename to apps/web/lib/fz_http_web/live/setting_live/customization_live.ex diff --git a/apps/fz_http/lib/fz_http_web/live/setting_live/new_api_token_component.ex b/apps/web/lib/fz_http_web/live/setting_live/new_api_token_component.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/live/setting_live/new_api_token_component.ex rename to apps/web/lib/fz_http_web/live/setting_live/new_api_token_component.ex diff --git a/apps/fz_http/lib/fz_http_web/live/setting_live/oidc_form_component.ex b/apps/web/lib/fz_http_web/live/setting_live/oidc_form_component.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/live/setting_live/oidc_form_component.ex rename to apps/web/lib/fz_http_web/live/setting_live/oidc_form_component.ex diff --git a/apps/fz_http/lib/fz_http_web/live/setting_live/saml_form_component.ex b/apps/web/lib/fz_http_web/live/setting_live/saml_form_component.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/live/setting_live/saml_form_component.ex rename to apps/web/lib/fz_http_web/live/setting_live/saml_form_component.ex diff --git a/apps/fz_http/lib/fz_http_web/live/setting_live/security.html.heex b/apps/web/lib/fz_http_web/live/setting_live/security.html.heex similarity index 100% rename from apps/fz_http/lib/fz_http_web/live/setting_live/security.html.heex rename to apps/web/lib/fz_http_web/live/setting_live/security.html.heex diff --git a/apps/fz_http/lib/fz_http_web/live/setting_live/security_live.ex b/apps/web/lib/fz_http_web/live/setting_live/security_live.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/live/setting_live/security_live.ex rename to apps/web/lib/fz_http_web/live/setting_live/security_live.ex diff --git a/apps/fz_http/lib/fz_http_web/live/setting_live/show_api_token_component.ex b/apps/web/lib/fz_http_web/live/setting_live/show_api_token_component.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/live/setting_live/show_api_token_component.ex rename to apps/web/lib/fz_http_web/live/setting_live/show_api_token_component.ex diff --git a/apps/fz_http/lib/fz_http_web/live/setting_live/unprivileged/account.html.heex b/apps/web/lib/fz_http_web/live/setting_live/unprivileged/account.html.heex similarity index 100% rename from apps/fz_http/lib/fz_http_web/live/setting_live/unprivileged/account.html.heex rename to apps/web/lib/fz_http_web/live/setting_live/unprivileged/account.html.heex diff --git a/apps/fz_http/lib/fz_http_web/live/setting_live/unprivileged/account_form_component.ex b/apps/web/lib/fz_http_web/live/setting_live/unprivileged/account_form_component.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/live/setting_live/unprivileged/account_form_component.ex rename to apps/web/lib/fz_http_web/live/setting_live/unprivileged/account_form_component.ex diff --git a/apps/fz_http/lib/fz_http_web/live/setting_live/unprivileged/account_form_component.html.heex b/apps/web/lib/fz_http_web/live/setting_live/unprivileged/account_form_component.html.heex similarity index 100% rename from apps/fz_http/lib/fz_http_web/live/setting_live/unprivileged/account_form_component.html.heex rename to apps/web/lib/fz_http_web/live/setting_live/unprivileged/account_form_component.html.heex diff --git a/apps/fz_http/lib/fz_http_web/live/setting_live/unprivileged/account_live.ex b/apps/web/lib/fz_http_web/live/setting_live/unprivileged/account_live.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/live/setting_live/unprivileged/account_live.ex rename to apps/web/lib/fz_http_web/live/setting_live/unprivileged/account_live.ex diff --git a/apps/fz_http/lib/fz_http_web/live/sidebar_component.ex b/apps/web/lib/fz_http_web/live/sidebar_component.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/live/sidebar_component.ex rename to apps/web/lib/fz_http_web/live/sidebar_component.ex diff --git a/apps/fz_http/lib/fz_http_web/live/user_live/form_component.ex b/apps/web/lib/fz_http_web/live/user_live/form_component.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/live/user_live/form_component.ex rename to apps/web/lib/fz_http_web/live/user_live/form_component.ex diff --git a/apps/fz_http/lib/fz_http_web/live/user_live/form_component.html.heex b/apps/web/lib/fz_http_web/live/user_live/form_component.html.heex similarity index 100% rename from apps/fz_http/lib/fz_http_web/live/user_live/form_component.html.heex rename to apps/web/lib/fz_http_web/live/user_live/form_component.html.heex diff --git a/apps/fz_http/lib/fz_http_web/live/user_live/index.html.heex b/apps/web/lib/fz_http_web/live/user_live/index.html.heex similarity index 100% rename from apps/fz_http/lib/fz_http_web/live/user_live/index.html.heex rename to apps/web/lib/fz_http_web/live/user_live/index.html.heex diff --git a/apps/fz_http/lib/fz_http_web/live/user_live/index_live.ex b/apps/web/lib/fz_http_web/live/user_live/index_live.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/live/user_live/index_live.ex rename to apps/web/lib/fz_http_web/live/user_live/index_live.ex diff --git a/apps/fz_http/lib/fz_http_web/live/user_live/show.html.heex b/apps/web/lib/fz_http_web/live/user_live/show.html.heex similarity index 100% rename from apps/fz_http/lib/fz_http_web/live/user_live/show.html.heex rename to apps/web/lib/fz_http_web/live/user_live/show.html.heex diff --git a/apps/fz_http/lib/fz_http_web/live/user_live/show_live.ex b/apps/web/lib/fz_http_web/live/user_live/show_live.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/live/user_live/show_live.ex rename to apps/web/lib/fz_http_web/live/user_live/show_live.ex diff --git a/apps/fz_http/lib/fz_http_web/live/user_live/vpn_connection_component.ex b/apps/web/lib/fz_http_web/live/user_live/vpn_connection_component.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/live/user_live/vpn_connection_component.ex rename to apps/web/lib/fz_http_web/live/user_live/vpn_connection_component.ex diff --git a/apps/fz_http/lib/fz_http_web/live/user_live/vpn_status_component.ex b/apps/web/lib/fz_http_web/live/user_live/vpn_status_component.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/live/user_live/vpn_status_component.ex rename to apps/web/lib/fz_http_web/live/user_live/vpn_status_component.ex diff --git a/apps/fz_http/lib/fz_http_web/live_helpers.ex b/apps/web/lib/fz_http_web/live_helpers.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/live_helpers.ex rename to apps/web/lib/fz_http_web/live_helpers.ex diff --git a/apps/fz_http/lib/fz_http_web/mailer.ex b/apps/web/lib/fz_http_web/mailer.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/mailer.ex rename to apps/web/lib/fz_http_web/mailer.ex diff --git a/apps/fz_http/lib/fz_http_web/mailer/auth_email.ex b/apps/web/lib/fz_http_web/mailer/auth_email.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/mailer/auth_email.ex rename to apps/web/lib/fz_http_web/mailer/auth_email.ex diff --git a/apps/fz_http/lib/fz_http_web/mailer/noop_adapter.ex b/apps/web/lib/fz_http_web/mailer/noop_adapter.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/mailer/noop_adapter.ex rename to apps/web/lib/fz_http_web/mailer/noop_adapter.ex diff --git a/apps/fz_http/lib/fz_http_web/mailer/templates/auth_email/magic_link.html.heex b/apps/web/lib/fz_http_web/mailer/templates/auth_email/magic_link.html.heex similarity index 100% rename from apps/fz_http/lib/fz_http_web/mailer/templates/auth_email/magic_link.html.heex rename to apps/web/lib/fz_http_web/mailer/templates/auth_email/magic_link.html.heex diff --git a/apps/fz_http/lib/fz_http_web/mailer/templates/auth_email/magic_link.text.eex b/apps/web/lib/fz_http_web/mailer/templates/auth_email/magic_link.text.eex similarity index 100% rename from apps/fz_http/lib/fz_http_web/mailer/templates/auth_email/magic_link.text.eex rename to apps/web/lib/fz_http_web/mailer/templates/auth_email/magic_link.text.eex diff --git a/apps/fz_http/lib/fz_http_web/oauth/pkce.ex b/apps/web/lib/fz_http_web/oauth/pkce.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/oauth/pkce.ex rename to apps/web/lib/fz_http_web/oauth/pkce.ex diff --git a/apps/fz_http/lib/fz_http_web/oidc/state.ex b/apps/web/lib/fz_http_web/oidc/state.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/oidc/state.ex rename to apps/web/lib/fz_http_web/oidc/state.ex diff --git a/apps/fz_http/lib/fz_http_web/plug/path_prefix.ex b/apps/web/lib/fz_http_web/plug/path_prefix.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/plug/path_prefix.ex rename to apps/web/lib/fz_http_web/plug/path_prefix.ex diff --git a/apps/fz_http/lib/fz_http_web/plug/require_local_authentication.ex b/apps/web/lib/fz_http_web/plug/require_local_authentication.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/plug/require_local_authentication.ex rename to apps/web/lib/fz_http_web/plug/require_local_authentication.ex diff --git a/apps/fz_http/lib/fz_http_web/plug/samly_target_url.ex b/apps/web/lib/fz_http_web/plug/samly_target_url.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/plug/samly_target_url.ex rename to apps/web/lib/fz_http_web/plug/samly_target_url.ex diff --git a/apps/fz_http/lib/fz_http_web/presence.ex b/apps/web/lib/fz_http_web/presence.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/presence.ex rename to apps/web/lib/fz_http_web/presence.ex diff --git a/apps/fz_http/lib/fz_http_web/proxy_headers.ex b/apps/web/lib/fz_http_web/proxy_headers.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/proxy_headers.ex rename to apps/web/lib/fz_http_web/proxy_headers.ex diff --git a/apps/fz_http/lib/fz_http_web/router.ex b/apps/web/lib/fz_http_web/router.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/router.ex rename to apps/web/lib/fz_http_web/router.ex diff --git a/apps/fz_http/lib/fz_http_web/sandbox.ex b/apps/web/lib/fz_http_web/sandbox.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/sandbox.ex rename to apps/web/lib/fz_http_web/sandbox.ex diff --git a/apps/fz_http/lib/fz_http_web/session.ex b/apps/web/lib/fz_http_web/session.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/session.ex rename to apps/web/lib/fz_http_web/session.ex diff --git a/apps/fz_http/lib/fz_http_web/sockets/user_socket.ex b/apps/web/lib/fz_http_web/sockets/user_socket.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/sockets/user_socket.ex rename to apps/web/lib/fz_http_web/sockets/user_socket.ex diff --git a/apps/fz_http/lib/fz_http_web/templates/auth/request.html.heex b/apps/web/lib/fz_http_web/templates/auth/request.html.heex similarity index 100% rename from apps/fz_http/lib/fz_http_web/templates/auth/request.html.heex rename to apps/web/lib/fz_http_web/templates/auth/request.html.heex diff --git a/apps/fz_http/lib/fz_http_web/templates/auth/reset_password.html.heex b/apps/web/lib/fz_http_web/templates/auth/reset_password.html.heex similarity index 100% rename from apps/fz_http/lib/fz_http_web/templates/auth/reset_password.html.heex rename to apps/web/lib/fz_http_web/templates/auth/reset_password.html.heex diff --git a/apps/fz_http/lib/fz_http_web/templates/browser/browserconfig.xml.eex b/apps/web/lib/fz_http_web/templates/browser/browserconfig.xml.eex similarity index 100% rename from apps/fz_http/lib/fz_http_web/templates/browser/browserconfig.xml.eex rename to apps/web/lib/fz_http_web/templates/browser/browserconfig.xml.eex diff --git a/apps/fz_http/lib/fz_http_web/templates/layout/admin.html.heex b/apps/web/lib/fz_http_web/templates/layout/admin.html.heex similarity index 100% rename from apps/fz_http/lib/fz_http_web/templates/layout/admin.html.heex rename to apps/web/lib/fz_http_web/templates/layout/admin.html.heex diff --git a/apps/fz_http/lib/fz_http_web/templates/layout/app.html.heex b/apps/web/lib/fz_http_web/templates/layout/app.html.heex similarity index 100% rename from apps/fz_http/lib/fz_http_web/templates/layout/app.html.heex rename to apps/web/lib/fz_http_web/templates/layout/app.html.heex diff --git a/apps/fz_http/lib/fz_http_web/templates/layout/email.html.heex b/apps/web/lib/fz_http_web/templates/layout/email.html.heex similarity index 100% rename from apps/fz_http/lib/fz_http_web/templates/layout/email.html.heex rename to apps/web/lib/fz_http_web/templates/layout/email.html.heex diff --git a/apps/fz_http/lib/fz_http_web/templates/layout/live.html.heex b/apps/web/lib/fz_http_web/templates/layout/live.html.heex similarity index 100% rename from apps/fz_http/lib/fz_http_web/templates/layout/live.html.heex rename to apps/web/lib/fz_http_web/templates/layout/live.html.heex diff --git a/apps/fz_http/lib/fz_http_web/templates/layout/root.html.heex b/apps/web/lib/fz_http_web/templates/layout/root.html.heex similarity index 100% rename from apps/fz_http/lib/fz_http_web/templates/layout/root.html.heex rename to apps/web/lib/fz_http_web/templates/layout/root.html.heex diff --git a/apps/fz_http/lib/fz_http_web/templates/layout/unprivileged.html.heex b/apps/web/lib/fz_http_web/templates/layout/unprivileged.html.heex similarity index 100% rename from apps/fz_http/lib/fz_http_web/templates/layout/unprivileged.html.heex rename to apps/web/lib/fz_http_web/templates/layout/unprivileged.html.heex diff --git a/apps/fz_http/lib/fz_http_web/templates/root/auth.html.heex b/apps/web/lib/fz_http_web/templates/root/auth.html.heex similarity index 100% rename from apps/fz_http/lib/fz_http_web/templates/root/auth.html.heex rename to apps/web/lib/fz_http_web/templates/root/auth.html.heex diff --git a/apps/fz_http/lib/fz_http_web/templates/shared/device_details.html.heex b/apps/web/lib/fz_http_web/templates/shared/device_details.html.heex similarity index 100% rename from apps/fz_http/lib/fz_http_web/templates/shared/device_details.html.heex rename to apps/web/lib/fz_http_web/templates/shared/device_details.html.heex diff --git a/apps/fz_http/lib/fz_http_web/templates/shared/devices_table.html.heex b/apps/web/lib/fz_http_web/templates/shared/devices_table.html.heex similarity index 100% rename from apps/fz_http/lib/fz_http_web/templates/shared/devices_table.html.heex rename to apps/web/lib/fz_http_web/templates/shared/devices_table.html.heex diff --git a/apps/fz_http/lib/fz_http_web/templates/shared/flash.html.heex b/apps/web/lib/fz_http_web/templates/shared/flash.html.heex similarity index 100% rename from apps/fz_http/lib/fz_http_web/templates/shared/flash.html.heex rename to apps/web/lib/fz_http_web/templates/shared/flash.html.heex diff --git a/apps/fz_http/lib/fz_http_web/templates/shared/head.html.heex b/apps/web/lib/fz_http_web/templates/shared/head.html.heex similarity index 100% rename from apps/fz_http/lib/fz_http_web/templates/shared/head.html.heex rename to apps/web/lib/fz_http_web/templates/shared/head.html.heex diff --git a/apps/fz_http/lib/fz_http_web/templates/shared/heading.html.heex b/apps/web/lib/fz_http_web/templates/shared/heading.html.heex similarity index 100% rename from apps/fz_http/lib/fz_http_web/templates/shared/heading.html.heex rename to apps/web/lib/fz_http_web/templates/shared/heading.html.heex diff --git a/apps/fz_http/lib/fz_http_web/templates/shared/mfa_methods_table.html.heex b/apps/web/lib/fz_http_web/templates/shared/mfa_methods_table.html.heex similarity index 100% rename from apps/fz_http/lib/fz_http_web/templates/shared/mfa_methods_table.html.heex rename to apps/web/lib/fz_http_web/templates/shared/mfa_methods_table.html.heex diff --git a/apps/fz_http/lib/fz_http_web/templates/shared/password_field.html.heex b/apps/web/lib/fz_http_web/templates/shared/password_field.html.heex similarity index 100% rename from apps/fz_http/lib/fz_http_web/templates/shared/password_field.html.heex rename to apps/web/lib/fz_http_web/templates/shared/password_field.html.heex diff --git a/apps/fz_http/lib/fz_http_web/templates/shared/show_device.html.heex b/apps/web/lib/fz_http_web/templates/shared/show_device.html.heex similarity index 100% rename from apps/fz_http/lib/fz_http_web/templates/shared/show_device.html.heex rename to apps/web/lib/fz_http_web/templates/shared/show_device.html.heex diff --git a/apps/fz_http/lib/fz_http_web/templates/shared/socket_token_headers.html.heex b/apps/web/lib/fz_http_web/templates/shared/socket_token_headers.html.heex similarity index 100% rename from apps/fz_http/lib/fz_http_web/templates/shared/socket_token_headers.html.heex rename to apps/web/lib/fz_http_web/templates/shared/socket_token_headers.html.heex diff --git a/apps/fz_http/lib/fz_http_web/templates/shared/submit_button.html.heex b/apps/web/lib/fz_http_web/templates/shared/submit_button.html.heex similarity index 100% rename from apps/fz_http/lib/fz_http_web/templates/shared/submit_button.html.heex rename to apps/web/lib/fz_http_web/templates/shared/submit_button.html.heex diff --git a/apps/fz_http/lib/fz_http_web/templates/shared/user_details.html.heex b/apps/web/lib/fz_http_web/templates/shared/user_details.html.heex similarity index 100% rename from apps/fz_http/lib/fz_http_web/templates/shared/user_details.html.heex rename to apps/web/lib/fz_http_web/templates/shared/user_details.html.heex diff --git a/apps/fz_http/lib/fz_http_web/user_from_auth.ex b/apps/web/lib/fz_http_web/user_from_auth.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/user_from_auth.ex rename to apps/web/lib/fz_http_web/user_from_auth.ex diff --git a/apps/fz_http/lib/fz_http_web/views/auth_view.ex b/apps/web/lib/fz_http_web/views/auth_view.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/views/auth_view.ex rename to apps/web/lib/fz_http_web/views/auth_view.ex diff --git a/apps/fz_http/lib/fz_http_web/views/browser_view.ex b/apps/web/lib/fz_http_web/views/browser_view.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/views/browser_view.ex rename to apps/web/lib/fz_http_web/views/browser_view.ex diff --git a/apps/fz_http/lib/fz_http_web/views/error_view.ex b/apps/web/lib/fz_http_web/views/error_view.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/views/error_view.ex rename to apps/web/lib/fz_http_web/views/error_view.ex diff --git a/apps/fz_http/lib/fz_http_web/views/json/changeset_view.ex b/apps/web/lib/fz_http_web/views/json/changeset_view.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/views/json/changeset_view.ex rename to apps/web/lib/fz_http_web/views/json/changeset_view.ex diff --git a/apps/fz_http/lib/fz_http_web/views/json/configuration_view.ex b/apps/web/lib/fz_http_web/views/json/configuration_view.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/views/json/configuration_view.ex rename to apps/web/lib/fz_http_web/views/json/configuration_view.ex diff --git a/apps/fz_http/lib/fz_http_web/views/json/device_view.ex b/apps/web/lib/fz_http_web/views/json/device_view.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/views/json/device_view.ex rename to apps/web/lib/fz_http_web/views/json/device_view.ex diff --git a/apps/fz_http/lib/fz_http_web/views/json/openid_connect_provider_view.ex b/apps/web/lib/fz_http_web/views/json/openid_connect_provider_view.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/views/json/openid_connect_provider_view.ex rename to apps/web/lib/fz_http_web/views/json/openid_connect_provider_view.ex diff --git a/apps/fz_http/lib/fz_http_web/views/json/rule_view.ex b/apps/web/lib/fz_http_web/views/json/rule_view.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/views/json/rule_view.ex rename to apps/web/lib/fz_http_web/views/json/rule_view.ex diff --git a/apps/fz_http/lib/fz_http_web/views/json/saml_identity_provider_view.ex b/apps/web/lib/fz_http_web/views/json/saml_identity_provider_view.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/views/json/saml_identity_provider_view.ex rename to apps/web/lib/fz_http_web/views/json/saml_identity_provider_view.ex diff --git a/apps/fz_http/lib/fz_http_web/views/json/user_view.ex b/apps/web/lib/fz_http_web/views/json/user_view.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/views/json/user_view.ex rename to apps/web/lib/fz_http_web/views/json/user_view.ex diff --git a/apps/fz_http/lib/fz_http_web/views/layout_view.ex b/apps/web/lib/fz_http_web/views/layout_view.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/views/layout_view.ex rename to apps/web/lib/fz_http_web/views/layout_view.ex diff --git a/apps/fz_http/lib/fz_http_web/views/root_view.ex b/apps/web/lib/fz_http_web/views/root_view.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/views/root_view.ex rename to apps/web/lib/fz_http_web/views/root_view.ex diff --git a/apps/fz_http/lib/fz_http_web/views/rule_view.ex b/apps/web/lib/fz_http_web/views/rule_view.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/views/rule_view.ex rename to apps/web/lib/fz_http_web/views/rule_view.ex diff --git a/apps/fz_http/lib/fz_http_web/views/shared_view.ex b/apps/web/lib/fz_http_web/views/shared_view.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/views/shared_view.ex rename to apps/web/lib/fz_http_web/views/shared_view.ex diff --git a/apps/fz_http/lib/fz_http_web/views/user_view.ex b/apps/web/lib/fz_http_web/views/user_view.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/views/user_view.ex rename to apps/web/lib/fz_http_web/views/user_view.ex diff --git a/apps/fz_http/lib/fz_http_web/views/wireguard_config_view.ex b/apps/web/lib/fz_http_web/views/wireguard_config_view.ex similarity index 100% rename from apps/fz_http/lib/fz_http_web/views/wireguard_config_view.ex rename to apps/web/lib/fz_http_web/views/wireguard_config_view.ex diff --git a/apps/fz_http/mix.exs b/apps/web/mix.exs similarity index 100% rename from apps/fz_http/mix.exs rename to apps/web/mix.exs diff --git a/apps/fz_http/priv/cert/saml_selfsigned.pem b/apps/web/priv/cert/saml_selfsigned.pem similarity index 100% rename from apps/fz_http/priv/cert/saml_selfsigned.pem rename to apps/web/priv/cert/saml_selfsigned.pem diff --git a/apps/fz_http/priv/cert/saml_selfsigned_key.pem b/apps/web/priv/cert/saml_selfsigned_key.pem similarity index 100% rename from apps/fz_http/priv/cert/saml_selfsigned_key.pem rename to apps/web/priv/cert/saml_selfsigned_key.pem diff --git a/apps/fz_http/priv/gettext/en/LC_MESSAGES/errors.po b/apps/web/priv/gettext/en/LC_MESSAGES/errors.po similarity index 100% rename from apps/fz_http/priv/gettext/en/LC_MESSAGES/errors.po rename to apps/web/priv/gettext/en/LC_MESSAGES/errors.po diff --git a/apps/fz_http/priv/gettext/errors.pot b/apps/web/priv/gettext/errors.pot similarity index 100% rename from apps/fz_http/priv/gettext/errors.pot rename to apps/web/priv/gettext/errors.pot diff --git a/apps/fz_http/priv/repo/migrations/20200225005454_create_users.exs b/apps/web/priv/repo/migrations/20200225005454_create_users.exs similarity index 100% rename from apps/fz_http/priv/repo/migrations/20200225005454_create_users.exs rename to apps/web/priv/repo/migrations/20200225005454_create_users.exs diff --git a/apps/fz_http/priv/repo/migrations/20200228145810_create_devices.exs b/apps/web/priv/repo/migrations/20200228145810_create_devices.exs similarity index 100% rename from apps/fz_http/priv/repo/migrations/20200228145810_create_devices.exs rename to apps/web/priv/repo/migrations/20200228145810_create_devices.exs diff --git a/apps/fz_http/priv/repo/migrations/20200228154815_create_rules.exs b/apps/web/priv/repo/migrations/20200228154815_create_rules.exs similarity index 100% rename from apps/fz_http/priv/repo/migrations/20200228154815_create_rules.exs rename to apps/web/priv/repo/migrations/20200228154815_create_rules.exs diff --git a/apps/fz_http/priv/repo/migrations/20210929172417_add_dns_servers_to_devices.exs b/apps/web/priv/repo/migrations/20210929172417_add_dns_servers_to_devices.exs similarity index 100% rename from apps/fz_http/priv/repo/migrations/20210929172417_add_dns_servers_to_devices.exs rename to apps/web/priv/repo/migrations/20210929172417_add_dns_servers_to_devices.exs diff --git a/apps/fz_http/priv/repo/migrations/20211116172808_create_connectivity_checks.exs b/apps/web/priv/repo/migrations/20211116172808_create_connectivity_checks.exs similarity index 100% rename from apps/fz_http/priv/repo/migrations/20211116172808_create_connectivity_checks.exs rename to apps/web/priv/repo/migrations/20211116172808_create_connectivity_checks.exs diff --git a/apps/fz_http/priv/repo/migrations/20211116173236_create_settings.exs b/apps/web/priv/repo/migrations/20211116173236_create_settings.exs similarity index 100% rename from apps/fz_http/priv/repo/migrations/20211116173236_create_settings.exs rename to apps/web/priv/repo/migrations/20211116173236_create_settings.exs diff --git a/apps/fz_http/priv/repo/migrations/20211203012238_change_device_column_defaults.exs b/apps/web/priv/repo/migrations/20211203012238_change_device_column_defaults.exs similarity index 100% rename from apps/fz_http/priv/repo/migrations/20211203012238_change_device_column_defaults.exs rename to apps/web/priv/repo/migrations/20211203012238_change_device_column_defaults.exs diff --git a/apps/fz_http/priv/repo/migrations/20211216155557_add_config_token_to_devices.exs b/apps/web/priv/repo/migrations/20211216155557_add_config_token_to_devices.exs similarity index 100% rename from apps/fz_http/priv/repo/migrations/20211216155557_add_config_token_to_devices.exs rename to apps/web/priv/repo/migrations/20211216155557_add_config_token_to_devices.exs diff --git a/apps/fz_http/priv/repo/migrations/20211217003247_add_persistent_keepalives.exs b/apps/web/priv/repo/migrations/20211217003247_add_persistent_keepalives.exs similarity index 100% rename from apps/fz_http/priv/repo/migrations/20211217003247_add_persistent_keepalives.exs rename to apps/web/priv/repo/migrations/20211217003247_add_persistent_keepalives.exs diff --git a/apps/fz_http/priv/repo/migrations/20211221183311_add_role_to_users.exs b/apps/web/priv/repo/migrations/20211221183311_add_role_to_users.exs similarity index 100% rename from apps/fz_http/priv/repo/migrations/20211221183311_add_role_to_users.exs rename to apps/web/priv/repo/migrations/20211221183311_add_role_to_users.exs diff --git a/apps/fz_http/priv/repo/migrations/20211223161545_add_require_auth_for_vpn_setting.exs b/apps/web/priv/repo/migrations/20211223161545_add_require_auth_for_vpn_setting.exs similarity index 100% rename from apps/fz_http/priv/repo/migrations/20211223161545_add_require_auth_for_vpn_setting.exs rename to apps/web/priv/repo/migrations/20211223161545_add_require_auth_for_vpn_setting.exs diff --git a/apps/fz_http/priv/repo/migrations/20220103175026_add_inets_to_devices.exs b/apps/web/priv/repo/migrations/20220103175026_add_inets_to_devices.exs similarity index 100% rename from apps/fz_http/priv/repo/migrations/20220103175026_add_inets_to_devices.exs rename to apps/web/priv/repo/migrations/20220103175026_add_inets_to_devices.exs diff --git a/apps/fz_http/priv/repo/migrations/20220111004847_add_mtu_to_devices.exs b/apps/web/priv/repo/migrations/20220111004847_add_mtu_to_devices.exs similarity index 100% rename from apps/fz_http/priv/repo/migrations/20220111004847_add_mtu_to_devices.exs rename to apps/web/priv/repo/migrations/20220111004847_add_mtu_to_devices.exs diff --git a/apps/fz_http/priv/repo/migrations/20220124162404_add_uuids.exs b/apps/web/priv/repo/migrations/20220124162404_add_uuids.exs similarity index 100% rename from apps/fz_http/priv/repo/migrations/20220124162404_add_uuids.exs rename to apps/web/priv/repo/migrations/20220124162404_add_uuids.exs diff --git a/apps/fz_http/priv/repo/migrations/20220127021835_rename_persistent_keepalives.exs b/apps/web/priv/repo/migrations/20220127021835_rename_persistent_keepalives.exs similarity index 100% rename from apps/fz_http/priv/repo/migrations/20220127021835_rename_persistent_keepalives.exs rename to apps/web/priv/repo/migrations/20220127021835_rename_persistent_keepalives.exs diff --git a/apps/fz_http/priv/repo/migrations/20220127191440_rename_dns_servers_to_dns.exs b/apps/web/priv/repo/migrations/20220127191440_rename_dns_servers_to_dns.exs similarity index 100% rename from apps/fz_http/priv/repo/migrations/20220127191440_rename_dns_servers_to_dns.exs rename to apps/web/priv/repo/migrations/20220127191440_rename_dns_servers_to_dns.exs diff --git a/apps/fz_http/priv/repo/migrations/20220208184257_settings_to_sites.exs b/apps/web/priv/repo/migrations/20220208184257_settings_to_sites.exs similarity index 100% rename from apps/fz_http/priv/repo/migrations/20220208184257_settings_to_sites.exs rename to apps/web/priv/repo/migrations/20220208184257_settings_to_sites.exs diff --git a/apps/fz_http/priv/repo/migrations/20220209005201_rename_use_default_to_use_site.exs b/apps/web/priv/repo/migrations/20220209005201_rename_use_default_to_use_site.exs similarity index 100% rename from apps/fz_http/priv/repo/migrations/20220209005201_rename_use_default_to_use_site.exs rename to apps/web/priv/repo/migrations/20220209005201_rename_use_default_to_use_site.exs diff --git a/apps/fz_http/priv/repo/migrations/20220211201727_remove_private_keys.exs b/apps/web/priv/repo/migrations/20220211201727_remove_private_keys.exs similarity index 100% rename from apps/fz_http/priv/repo/migrations/20220211201727_remove_private_keys.exs rename to apps/web/priv/repo/migrations/20220211201727_remove_private_keys.exs diff --git a/apps/fz_http/priv/repo/migrations/20220219165023_add_key_regenerated_at.exs b/apps/web/priv/repo/migrations/20220219165023_add_key_regenerated_at.exs similarity index 100% rename from apps/fz_http/priv/repo/migrations/20220219165023_add_key_regenerated_at.exs rename to apps/web/priv/repo/migrations/20220219165023_add_key_regenerated_at.exs diff --git a/apps/fz_http/priv/repo/migrations/20220227215313_add_last_signed_in_method_to_user.exs b/apps/web/priv/repo/migrations/20220227215313_add_last_signed_in_method_to_user.exs similarity index 100% rename from apps/fz_http/priv/repo/migrations/20220227215313_add_last_signed_in_method_to_user.exs rename to apps/web/priv/repo/migrations/20220227215313_add_last_signed_in_method_to_user.exs diff --git a/apps/fz_http/priv/repo/migrations/20220412144151_add_psk_to_devices.exs b/apps/web/priv/repo/migrations/20220412144151_add_psk_to_devices.exs similarity index 100% rename from apps/fz_http/priv/repo/migrations/20220412144151_add_psk_to_devices.exs rename to apps/web/priv/repo/migrations/20220412144151_add_psk_to_devices.exs diff --git a/apps/fz_http/priv/repo/migrations/20220419172036_add_stats_to_devices.exs b/apps/web/priv/repo/migrations/20220419172036_add_stats_to_devices.exs similarity index 100% rename from apps/fz_http/priv/repo/migrations/20220419172036_add_stats_to_devices.exs rename to apps/web/priv/repo/migrations/20220419172036_add_stats_to_devices.exs diff --git a/apps/fz_http/priv/repo/migrations/20220427140943_add_description_to_devices.exs b/apps/web/priv/repo/migrations/20220427140943_add_description_to_devices.exs similarity index 100% rename from apps/fz_http/priv/repo/migrations/20220427140943_add_description_to_devices.exs rename to apps/web/priv/repo/migrations/20220427140943_add_description_to_devices.exs diff --git a/apps/fz_http/priv/repo/migrations/20220516063916_change_allowed_ips_to_text.exs b/apps/web/priv/repo/migrations/20220516063916_change_allowed_ips_to_text.exs similarity index 100% rename from apps/fz_http/priv/repo/migrations/20220516063916_change_allowed_ips_to_text.exs rename to apps/web/priv/repo/migrations/20220516063916_change_allowed_ips_to_text.exs diff --git a/apps/fz_http/priv/repo/migrations/20220519034545_create_oidc_connections.exs b/apps/web/priv/repo/migrations/20220519034545_create_oidc_connections.exs similarity index 100% rename from apps/fz_http/priv/repo/migrations/20220519034545_create_oidc_connections.exs rename to apps/web/priv/repo/migrations/20220519034545_create_oidc_connections.exs diff --git a/apps/fz_http/priv/repo/migrations/20220520072323_add_disabled_at_to_user.exs b/apps/web/priv/repo/migrations/20220520072323_add_disabled_at_to_user.exs similarity index 100% rename from apps/fz_http/priv/repo/migrations/20220520072323_add_disabled_at_to_user.exs rename to apps/web/priv/repo/migrations/20220520072323_add_disabled_at_to_user.exs diff --git a/apps/fz_http/priv/repo/migrations/20220530073152_create_mfa_methods.exs b/apps/web/priv/repo/migrations/20220530073152_create_mfa_methods.exs similarity index 100% rename from apps/fz_http/priv/repo/migrations/20220530073152_create_mfa_methods.exs rename to apps/web/priv/repo/migrations/20220530073152_create_mfa_methods.exs diff --git a/apps/fz_http/priv/repo/migrations/20220609232854_change_refresh_token_to_text.exs b/apps/web/priv/repo/migrations/20220609232854_change_refresh_token_to_text.exs similarity index 100% rename from apps/fz_http/priv/repo/migrations/20220609232854_change_refresh_token_to_text.exs rename to apps/web/priv/repo/migrations/20220609232854_change_refresh_token_to_text.exs diff --git a/apps/fz_http/priv/repo/migrations/20220614192937_add_user_id_to_rules.exs b/apps/web/priv/repo/migrations/20220614192937_add_user_id_to_rules.exs similarity index 100% rename from apps/fz_http/priv/repo/migrations/20220614192937_add_user_id_to_rules.exs rename to apps/web/priv/repo/migrations/20220614192937_add_user_id_to_rules.exs diff --git a/apps/fz_http/priv/repo/migrations/20220713050742_create_configurations.exs b/apps/web/priv/repo/migrations/20220713050742_create_configurations.exs similarity index 100% rename from apps/fz_http/priv/repo/migrations/20220713050742_create_configurations.exs rename to apps/web/priv/repo/migrations/20220713050742_create_configurations.exs diff --git a/apps/fz_http/priv/repo/migrations/20220719014442_add_auth_configs.exs b/apps/web/priv/repo/migrations/20220719014442_add_auth_configs.exs similarity index 100% rename from apps/fz_http/priv/repo/migrations/20220719014442_add_auth_configs.exs rename to apps/web/priv/repo/migrations/20220719014442_add_auth_configs.exs diff --git a/apps/fz_http/priv/repo/migrations/20220721164925_add_device_rule_user_notify_triggers.exs b/apps/web/priv/repo/migrations/20220721164925_add_device_rule_user_notify_triggers.exs similarity index 100% rename from apps/fz_http/priv/repo/migrations/20220721164925_add_device_rule_user_notify_triggers.exs rename to apps/web/priv/repo/migrations/20220721164925_add_device_rule_user_notify_triggers.exs diff --git a/apps/fz_http/priv/repo/migrations/20220726205646_add_rule_port_range.exs b/apps/web/priv/repo/migrations/20220726205646_add_rule_port_range.exs similarity index 100% rename from apps/fz_http/priv/repo/migrations/20220726205646_add_rule_port_range.exs rename to apps/web/priv/repo/migrations/20220726205646_add_rule_port_range.exs diff --git a/apps/fz_http/priv/repo/migrations/20220810002432_add_unprivileged_device_configuration.exs b/apps/web/priv/repo/migrations/20220810002432_add_unprivileged_device_configuration.exs similarity index 100% rename from apps/fz_http/priv/repo/migrations/20220810002432_add_unprivileged_device_configuration.exs rename to apps/web/priv/repo/migrations/20220810002432_add_unprivileged_device_configuration.exs diff --git a/apps/fz_http/priv/repo/migrations/20220831060724_add_saml_identity_providers_to_configuration.exs b/apps/web/priv/repo/migrations/20220831060724_add_saml_identity_providers_to_configuration.exs similarity index 100% rename from apps/fz_http/priv/repo/migrations/20220831060724_add_saml_identity_providers_to_configuration.exs rename to apps/web/priv/repo/migrations/20220831060724_add_saml_identity_providers_to_configuration.exs diff --git a/apps/fz_http/priv/repo/migrations/20221012123308_move_auto_create_users_to_providers.exs b/apps/web/priv/repo/migrations/20221012123308_move_auto_create_users_to_providers.exs similarity index 100% rename from apps/fz_http/priv/repo/migrations/20221012123308_move_auto_create_users_to_providers.exs rename to apps/web/priv/repo/migrations/20221012123308_move_auto_create_users_to_providers.exs diff --git a/apps/fz_http/priv/repo/migrations/20221129002233_update_on_delete_behavior.exs b/apps/web/priv/repo/migrations/20221129002233_update_on_delete_behavior.exs similarity index 100% rename from apps/fz_http/priv/repo/migrations/20221129002233_update_on_delete_behavior.exs rename to apps/web/priv/repo/migrations/20221129002233_update_on_delete_behavior.exs diff --git a/apps/fz_http/priv/repo/migrations/20221223190406_migrate_pks_to_uuid.exs b/apps/web/priv/repo/migrations/20221223190406_migrate_pks_to_uuid.exs similarity index 100% rename from apps/fz_http/priv/repo/migrations/20221223190406_migrate_pks_to_uuid.exs rename to apps/web/priv/repo/migrations/20221223190406_migrate_pks_to_uuid.exs diff --git a/apps/fz_http/priv/repo/migrations/20221223223357_migrate_datetimes_to_timestamptz.exs b/apps/web/priv/repo/migrations/20221223223357_migrate_datetimes_to_timestamptz.exs similarity index 100% rename from apps/fz_http/priv/repo/migrations/20221223223357_migrate_datetimes_to_timestamptz.exs rename to apps/web/priv/repo/migrations/20221223223357_migrate_datetimes_to_timestamptz.exs diff --git a/apps/fz_http/priv/repo/migrations/20221223223931_order_connectivity_checks_inserted_at_index.exs b/apps/web/priv/repo/migrations/20221223223931_order_connectivity_checks_inserted_at_index.exs similarity index 100% rename from apps/fz_http/priv/repo/migrations/20221223223931_order_connectivity_checks_inserted_at_index.exs rename to apps/web/priv/repo/migrations/20221223223931_order_connectivity_checks_inserted_at_index.exs diff --git a/apps/fz_http/priv/repo/migrations/20221224210654_fix_sites_nullable_fields.exs b/apps/web/priv/repo/migrations/20221224210654_fix_sites_nullable_fields.exs similarity index 100% rename from apps/fz_http/priv/repo/migrations/20221224210654_fix_sites_nullable_fields.exs rename to apps/web/priv/repo/migrations/20221224210654_fix_sites_nullable_fields.exs diff --git a/apps/fz_http/priv/repo/migrations/20221226044850_create_api_tokens.exs b/apps/web/priv/repo/migrations/20221226044850_create_api_tokens.exs similarity index 100% rename from apps/fz_http/priv/repo/migrations/20221226044850_create_api_tokens.exs rename to apps/web/priv/repo/migrations/20221226044850_create_api_tokens.exs diff --git a/apps/fz_http/priv/repo/migrations/20221226143651_move_sites_fields_to_configurations.exs b/apps/web/priv/repo/migrations/20221226143651_move_sites_fields_to_configurations.exs similarity index 100% rename from apps/fz_http/priv/repo/migrations/20221226143651_move_sites_fields_to_configurations.exs rename to apps/web/priv/repo/migrations/20221226143651_move_sites_fields_to_configurations.exs diff --git a/apps/fz_http/priv/repo/migrations/20221226171558_rename_use_site_to_use_default.exs b/apps/web/priv/repo/migrations/20221226171558_rename_use_site_to_use_default.exs similarity index 100% rename from apps/fz_http/priv/repo/migrations/20221226171558_rename_use_site_to_use_default.exs rename to apps/web/priv/repo/migrations/20221226171558_rename_use_site_to_use_default.exs diff --git a/apps/fz_http/priv/repo/migrations/20221226193228_drop_sites.exs b/apps/web/priv/repo/migrations/20221226193228_drop_sites.exs similarity index 100% rename from apps/fz_http/priv/repo/migrations/20221226193228_drop_sites.exs rename to apps/web/priv/repo/migrations/20221226193228_drop_sites.exs diff --git a/apps/fz_http/priv/repo/migrations/20221227181727_move_cache_fallbacks_to_configurations.exs b/apps/web/priv/repo/migrations/20221227181727_move_cache_fallbacks_to_configurations.exs similarity index 100% rename from apps/fz_http/priv/repo/migrations/20221227181727_move_cache_fallbacks_to_configurations.exs rename to apps/web/priv/repo/migrations/20221227181727_move_cache_fallbacks_to_configurations.exs diff --git a/apps/fz_http/priv/repo/migrations/20221229154115_migrate_providers_configs.exs b/apps/web/priv/repo/migrations/20221229154115_migrate_providers_configs.exs similarity index 100% rename from apps/fz_http/priv/repo/migrations/20221229154115_migrate_providers_configs.exs rename to apps/web/priv/repo/migrations/20221229154115_migrate_providers_configs.exs diff --git a/apps/fz_http/priv/repo/migrations/20230104000803_add_users_sign_in_token_hash.exs b/apps/web/priv/repo/migrations/20230104000803_add_users_sign_in_token_hash.exs similarity index 100% rename from apps/fz_http/priv/repo/migrations/20230104000803_add_users_sign_in_token_hash.exs rename to apps/web/priv/repo/migrations/20230104000803_add_users_sign_in_token_hash.exs diff --git a/apps/fz_http/priv/repo/migrations/20230104181853_change_users_email_to_citext.exs b/apps/web/priv/repo/migrations/20230104181853_change_users_email_to_citext.exs similarity index 100% rename from apps/fz_http/priv/repo/migrations/20230104181853_change_users_email_to_citext.exs rename to apps/web/priv/repo/migrations/20230104181853_change_users_email_to_citext.exs diff --git a/apps/fz_http/priv/repo/migrations/20230113184557_add_default_pks_values.exs b/apps/web/priv/repo/migrations/20230113184557_add_default_pks_values.exs similarity index 100% rename from apps/fz_http/priv/repo/migrations/20230113184557_add_default_pks_values.exs rename to apps/web/priv/repo/migrations/20230113184557_add_default_pks_values.exs diff --git a/apps/fz_http/priv/repo/migrations/20230116200524_add_not_null_to_mfa_methods.exs b/apps/web/priv/repo/migrations/20230116200524_add_not_null_to_mfa_methods.exs similarity index 100% rename from apps/fz_http/priv/repo/migrations/20230116200524_add_not_null_to_mfa_methods.exs rename to apps/web/priv/repo/migrations/20230116200524_add_not_null_to_mfa_methods.exs diff --git a/apps/fz_http/priv/repo/migrations/20230127164048_change_configurations_default_client_allowed_ips_type.exs b/apps/web/priv/repo/migrations/20230127164048_change_configurations_default_client_allowed_ips_type.exs similarity index 100% rename from apps/fz_http/priv/repo/migrations/20230127164048_change_configurations_default_client_allowed_ips_type.exs rename to apps/web/priv/repo/migrations/20230127164048_change_configurations_default_client_allowed_ips_type.exs diff --git a/apps/fz_http/priv/repo/migrations/20230203143621_change_mfa_methods_unique_index.exs b/apps/web/priv/repo/migrations/20230203143621_change_mfa_methods_unique_index.exs similarity index 100% rename from apps/fz_http/priv/repo/migrations/20230203143621_change_mfa_methods_unique_index.exs rename to apps/web/priv/repo/migrations/20230203143621_change_mfa_methods_unique_index.exs diff --git a/apps/fz_http/priv/repo/migrations/20230206172556_change_dns_and_allowed_ips_to_inet_array.exs b/apps/web/priv/repo/migrations/20230206172556_change_dns_and_allowed_ips_to_inet_array.exs similarity index 100% rename from apps/fz_http/priv/repo/migrations/20230206172556_change_dns_and_allowed_ips_to_inet_array.exs rename to apps/web/priv/repo/migrations/20230206172556_change_dns_and_allowed_ips_to_inet_array.exs diff --git a/apps/fz_http/priv/repo/migrations/20230223175621_trim_dns_fields.exs b/apps/web/priv/repo/migrations/20230223175621_trim_dns_fields.exs similarity index 100% rename from apps/fz_http/priv/repo/migrations/20230223175621_trim_dns_fields.exs rename to apps/web/priv/repo/migrations/20230223175621_trim_dns_fields.exs diff --git a/apps/fz_http/priv/repo/migrations/20230317161258_remove_devices_key_regenerated_at.exs b/apps/web/priv/repo/migrations/20230317161258_remove_devices_key_regenerated_at.exs similarity index 100% rename from apps/fz_http/priv/repo/migrations/20230317161258_remove_devices_key_regenerated_at.exs rename to apps/web/priv/repo/migrations/20230317161258_remove_devices_key_regenerated_at.exs diff --git a/apps/fz_http/priv/repo/seeds.exs b/apps/web/priv/repo/seeds.exs similarity index 100% rename from apps/fz_http/priv/repo/seeds.exs rename to apps/web/priv/repo/seeds.exs diff --git a/apps/fz_http/priv/static/images/android-chrome-192x192.png b/apps/web/priv/static/images/android-chrome-192x192.png similarity index 100% rename from apps/fz_http/priv/static/images/android-chrome-192x192.png rename to apps/web/priv/static/images/android-chrome-192x192.png diff --git a/apps/fz_http/priv/static/images/android-chrome-512x512.png b/apps/web/priv/static/images/android-chrome-512x512.png similarity index 100% rename from apps/fz_http/priv/static/images/android-chrome-512x512.png rename to apps/web/priv/static/images/android-chrome-512x512.png diff --git a/apps/fz_http/priv/static/images/apple-touch-icon.png b/apps/web/priv/static/images/apple-touch-icon.png similarity index 100% rename from apps/fz_http/priv/static/images/apple-touch-icon.png rename to apps/web/priv/static/images/apple-touch-icon.png diff --git a/apps/fz_http/priv/static/images/favicon-16x16.png b/apps/web/priv/static/images/favicon-16x16.png similarity index 100% rename from apps/fz_http/priv/static/images/favicon-16x16.png rename to apps/web/priv/static/images/favicon-16x16.png diff --git a/apps/fz_http/priv/static/images/favicon-32x32.png b/apps/web/priv/static/images/favicon-32x32.png similarity index 100% rename from apps/fz_http/priv/static/images/favicon-32x32.png rename to apps/web/priv/static/images/favicon-32x32.png diff --git a/apps/fz_http/priv/static/images/favicon.ico b/apps/web/priv/static/images/favicon.ico similarity index 100% rename from apps/fz_http/priv/static/images/favicon.ico rename to apps/web/priv/static/images/favicon.ico diff --git a/apps/fz_http/priv/static/images/logo-text.svg b/apps/web/priv/static/images/logo-text.svg similarity index 100% rename from apps/fz_http/priv/static/images/logo-text.svg rename to apps/web/priv/static/images/logo-text.svg diff --git a/apps/fz_http/priv/static/images/logo.svg b/apps/web/priv/static/images/logo.svg similarity index 100% rename from apps/fz_http/priv/static/images/logo.svg rename to apps/web/priv/static/images/logo.svg diff --git a/apps/fz_http/priv/static/images/mstile-150x150.png b/apps/web/priv/static/images/mstile-150x150.png similarity index 100% rename from apps/fz_http/priv/static/images/mstile-150x150.png rename to apps/web/priv/static/images/mstile-150x150.png diff --git a/apps/fz_http/priv/static/robots.txt b/apps/web/priv/static/robots.txt similarity index 100% rename from apps/fz_http/priv/static/robots.txt rename to apps/web/priv/static/robots.txt diff --git a/apps/fz_http/priv/static/site.webmanifest b/apps/web/priv/static/site.webmanifest similarity index 100% rename from apps/fz_http/priv/static/site.webmanifest rename to apps/web/priv/static/site.webmanifest diff --git a/apps/fz_http/test/fz_http/api_tokens_test.exs b/apps/web/test/fz_http/api_tokens_test.exs similarity index 100% rename from apps/fz_http/test/fz_http/api_tokens_test.exs rename to apps/web/test/fz_http/api_tokens_test.exs diff --git a/apps/fz_http/test/fz_http/auth/mfa_test.exs b/apps/web/test/fz_http/auth/mfa_test.exs similarity index 100% rename from apps/fz_http/test/fz_http/auth/mfa_test.exs rename to apps/web/test/fz_http/auth/mfa_test.exs diff --git a/apps/fz_http/test/fz_http/auth/oidc/refresher_test.exs b/apps/web/test/fz_http/auth/oidc/refresher_test.exs similarity index 100% rename from apps/fz_http/test/fz_http/auth/oidc/refresher_test.exs rename to apps/web/test/fz_http/auth/oidc/refresher_test.exs diff --git a/apps/fz_http/test/fz_http/auth_test.exs b/apps/web/test/fz_http/auth_test.exs similarity index 100% rename from apps/fz_http/test/fz_http/auth_test.exs rename to apps/web/test/fz_http/auth_test.exs diff --git a/apps/fz_http/test/fz_http/config/caster_test.exs b/apps/web/test/fz_http/config/caster_test.exs similarity index 100% rename from apps/fz_http/test/fz_http/config/caster_test.exs rename to apps/web/test/fz_http/config/caster_test.exs diff --git a/apps/fz_http/test/fz_http/config/definition_test.exs b/apps/web/test/fz_http/config/definition_test.exs similarity index 100% rename from apps/fz_http/test/fz_http/config/definition_test.exs rename to apps/web/test/fz_http/config/definition_test.exs diff --git a/apps/fz_http/test/fz_http/config/fetcher_test.exs b/apps/web/test/fz_http/config/fetcher_test.exs similarity index 100% rename from apps/fz_http/test/fz_http/config/fetcher_test.exs rename to apps/web/test/fz_http/config/fetcher_test.exs diff --git a/apps/fz_http/test/fz_http/config/resolver_test.exs b/apps/web/test/fz_http/config/resolver_test.exs similarity index 100% rename from apps/fz_http/test/fz_http/config/resolver_test.exs rename to apps/web/test/fz_http/config/resolver_test.exs diff --git a/apps/fz_http/test/fz_http/config/validator_test.exs b/apps/web/test/fz_http/config/validator_test.exs similarity index 100% rename from apps/fz_http/test/fz_http/config/validator_test.exs rename to apps/web/test/fz_http/config/validator_test.exs diff --git a/apps/fz_http/test/fz_http/config_test.exs b/apps/web/test/fz_http/config_test.exs similarity index 100% rename from apps/fz_http/test/fz_http/config_test.exs rename to apps/web/test/fz_http/config_test.exs diff --git a/apps/fz_http/test/fz_http/connectivity_checks/poller_test.exs b/apps/web/test/fz_http/connectivity_checks/poller_test.exs similarity index 100% rename from apps/fz_http/test/fz_http/connectivity_checks/poller_test.exs rename to apps/web/test/fz_http/connectivity_checks/poller_test.exs diff --git a/apps/fz_http/test/fz_http/connectivity_checks_test.exs b/apps/web/test/fz_http/connectivity_checks_test.exs similarity index 100% rename from apps/fz_http/test/fz_http/connectivity_checks_test.exs rename to apps/web/test/fz_http/connectivity_checks_test.exs diff --git a/apps/fz_http/test/fz_http/crypto_test.exs b/apps/web/test/fz_http/crypto_test.exs similarity index 100% rename from apps/fz_http/test/fz_http/crypto_test.exs rename to apps/web/test/fz_http/crypto_test.exs diff --git a/apps/fz_http/test/fz_http/devices/device/query_test.exs b/apps/web/test/fz_http/devices/device/query_test.exs similarity index 100% rename from apps/fz_http/test/fz_http/devices/device/query_test.exs rename to apps/web/test/fz_http/devices/device/query_test.exs diff --git a/apps/fz_http/test/fz_http/devices/stats_updater_test.exs b/apps/web/test/fz_http/devices/stats_updater_test.exs similarity index 100% rename from apps/fz_http/test/fz_http/devices/stats_updater_test.exs rename to apps/web/test/fz_http/devices/stats_updater_test.exs diff --git a/apps/fz_http/test/fz_http/devices_test.exs b/apps/web/test/fz_http/devices_test.exs similarity index 100% rename from apps/fz_http/test/fz_http/devices_test.exs rename to apps/web/test/fz_http/devices_test.exs diff --git a/apps/fz_http/test/fz_http/events_test.exs b/apps/web/test/fz_http/events_test.exs similarity index 100% rename from apps/fz_http/test/fz_http/events_test.exs rename to apps/web/test/fz_http/events_test.exs diff --git a/apps/fz_http/test/fz_http/name_generator_test.exs b/apps/web/test/fz_http/name_generator_test.exs similarity index 100% rename from apps/fz_http/test/fz_http/name_generator_test.exs rename to apps/web/test/fz_http/name_generator_test.exs diff --git a/apps/fz_http/test/fz_http/notifications_test.exs b/apps/web/test/fz_http/notifications_test.exs similarity index 100% rename from apps/fz_http/test/fz_http/notifications_test.exs rename to apps/web/test/fz_http/notifications_test.exs diff --git a/apps/fz_http/test/fz_http/release_test.exs b/apps/web/test/fz_http/release_test.exs similarity index 100% rename from apps/fz_http/test/fz_http/release_test.exs rename to apps/web/test/fz_http/release_test.exs diff --git a/apps/fz_http/test/fz_http/repo/notifier_test.exs b/apps/web/test/fz_http/repo/notifier_test.exs similarity index 100% rename from apps/fz_http/test/fz_http/repo/notifier_test.exs rename to apps/web/test/fz_http/repo/notifier_test.exs diff --git a/apps/fz_http/test/fz_http/rules_test.exs b/apps/web/test/fz_http/rules_test.exs similarity index 100% rename from apps/fz_http/test/fz_http/rules_test.exs rename to apps/web/test/fz_http/rules_test.exs diff --git a/apps/fz_http/test/fz_http/telemetry_test.exs b/apps/web/test/fz_http/telemetry_test.exs similarity index 100% rename from apps/fz_http/test/fz_http/telemetry_test.exs rename to apps/web/test/fz_http/telemetry_test.exs diff --git a/apps/fz_http/test/fz_http/types/cidr_test.exs b/apps/web/test/fz_http/types/cidr_test.exs similarity index 100% rename from apps/fz_http/test/fz_http/types/cidr_test.exs rename to apps/web/test/fz_http/types/cidr_test.exs diff --git a/apps/fz_http/test/fz_http/users_test.exs b/apps/web/test/fz_http/users_test.exs similarity index 100% rename from apps/fz_http/test/fz_http/users_test.exs rename to apps/web/test/fz_http/users_test.exs diff --git a/apps/fz_http/test/fz_http_web/acceptance/admin_test.exs b/apps/web/test/fz_http_web/acceptance/admin_test.exs similarity index 100% rename from apps/fz_http/test/fz_http_web/acceptance/admin_test.exs rename to apps/web/test/fz_http_web/acceptance/admin_test.exs diff --git a/apps/fz_http/test/fz_http_web/acceptance/authentication_test.exs b/apps/web/test/fz_http_web/acceptance/authentication_test.exs similarity index 100% rename from apps/fz_http/test/fz_http_web/acceptance/authentication_test.exs rename to apps/web/test/fz_http_web/acceptance/authentication_test.exs diff --git a/apps/fz_http/test/fz_http_web/acceptance/unprivileged_user_test.exs b/apps/web/test/fz_http_web/acceptance/unprivileged_user_test.exs similarity index 100% rename from apps/fz_http/test/fz_http_web/acceptance/unprivileged_user_test.exs rename to apps/web/test/fz_http_web/acceptance/unprivileged_user_test.exs diff --git a/apps/fz_http/test/fz_http_web/auth/json/authentication_test.exs b/apps/web/test/fz_http_web/auth/json/authentication_test.exs similarity index 100% rename from apps/fz_http/test/fz_http_web/auth/json/authentication_test.exs rename to apps/web/test/fz_http_web/auth/json/authentication_test.exs diff --git a/apps/fz_http/test/fz_http_web/channels/notification_channel_test.exs b/apps/web/test/fz_http_web/channels/notification_channel_test.exs similarity index 100% rename from apps/fz_http/test/fz_http_web/channels/notification_channel_test.exs rename to apps/web/test/fz_http_web/channels/notification_channel_test.exs diff --git a/apps/fz_http/test/fz_http_web/controllers/auth_controller_test.exs b/apps/web/test/fz_http_web/controllers/auth_controller_test.exs similarity index 100% rename from apps/fz_http/test/fz_http_web/controllers/auth_controller_test.exs rename to apps/web/test/fz_http_web/controllers/auth_controller_test.exs diff --git a/apps/fz_http/test/fz_http_web/controllers/browser_controller_test.exs b/apps/web/test/fz_http_web/controllers/browser_controller_test.exs similarity index 100% rename from apps/fz_http/test/fz_http_web/controllers/browser_controller_test.exs rename to apps/web/test/fz_http_web/controllers/browser_controller_test.exs diff --git a/apps/fz_http/test/fz_http_web/controllers/json/configuration_controller_test.exs b/apps/web/test/fz_http_web/controllers/json/configuration_controller_test.exs similarity index 100% rename from apps/fz_http/test/fz_http_web/controllers/json/configuration_controller_test.exs rename to apps/web/test/fz_http_web/controllers/json/configuration_controller_test.exs diff --git a/apps/fz_http/test/fz_http_web/controllers/json/device_controller_test.exs b/apps/web/test/fz_http_web/controllers/json/device_controller_test.exs similarity index 100% rename from apps/fz_http/test/fz_http_web/controllers/json/device_controller_test.exs rename to apps/web/test/fz_http_web/controllers/json/device_controller_test.exs diff --git a/apps/fz_http/test/fz_http_web/controllers/json/rule_controller_test.exs b/apps/web/test/fz_http_web/controllers/json/rule_controller_test.exs similarity index 100% rename from apps/fz_http/test/fz_http_web/controllers/json/rule_controller_test.exs rename to apps/web/test/fz_http_web/controllers/json/rule_controller_test.exs diff --git a/apps/fz_http/test/fz_http_web/controllers/json/user_controller_test.exs b/apps/web/test/fz_http_web/controllers/json/user_controller_test.exs similarity index 100% rename from apps/fz_http/test/fz_http_web/controllers/json/user_controller_test.exs rename to apps/web/test/fz_http_web/controllers/json/user_controller_test.exs diff --git a/apps/fz_http/test/fz_http_web/controllers/user_controller_test.exs b/apps/web/test/fz_http_web/controllers/user_controller_test.exs similarity index 100% rename from apps/fz_http/test/fz_http_web/controllers/user_controller_test.exs rename to apps/web/test/fz_http_web/controllers/user_controller_test.exs diff --git a/apps/fz_http/test/fz_http_web/header_helpers_test.exs b/apps/web/test/fz_http_web/header_helpers_test.exs similarity index 100% rename from apps/fz_http/test/fz_http_web/header_helpers_test.exs rename to apps/web/test/fz_http_web/header_helpers_test.exs diff --git a/apps/fz_http/test/fz_http_web/html_authentication_test.exs b/apps/web/test/fz_http_web/html_authentication_test.exs similarity index 100% rename from apps/fz_http/test/fz_http_web/html_authentication_test.exs rename to apps/web/test/fz_http_web/html_authentication_test.exs diff --git a/apps/fz_http/test/fz_http_web/layout_view_test.exs b/apps/web/test/fz_http_web/layout_view_test.exs similarity index 100% rename from apps/fz_http/test/fz_http_web/layout_view_test.exs rename to apps/web/test/fz_http_web/layout_view_test.exs diff --git a/apps/fz_http/test/fz_http_web/live/connectivity_check_live/index_test.exs b/apps/web/test/fz_http_web/live/connectivity_check_live/index_test.exs similarity index 100% rename from apps/fz_http/test/fz_http_web/live/connectivity_check_live/index_test.exs rename to apps/web/test/fz_http_web/live/connectivity_check_live/index_test.exs diff --git a/apps/fz_http/test/fz_http_web/live/device_live/admin/index_test.exs b/apps/web/test/fz_http_web/live/device_live/admin/index_test.exs similarity index 100% rename from apps/fz_http/test/fz_http_web/live/device_live/admin/index_test.exs rename to apps/web/test/fz_http_web/live/device_live/admin/index_test.exs diff --git a/apps/fz_http/test/fz_http_web/live/device_live/admin/show_test.exs b/apps/web/test/fz_http_web/live/device_live/admin/show_test.exs similarity index 100% rename from apps/fz_http/test/fz_http_web/live/device_live/admin/show_test.exs rename to apps/web/test/fz_http_web/live/device_live/admin/show_test.exs diff --git a/apps/fz_http/test/fz_http_web/live/device_live/unprivileged/index_test.exs b/apps/web/test/fz_http_web/live/device_live/unprivileged/index_test.exs similarity index 100% rename from apps/fz_http/test/fz_http_web/live/device_live/unprivileged/index_test.exs rename to apps/web/test/fz_http_web/live/device_live/unprivileged/index_test.exs diff --git a/apps/fz_http/test/fz_http_web/live/device_live/unprivileged/show_test.exs b/apps/web/test/fz_http_web/live/device_live/unprivileged/show_test.exs similarity index 100% rename from apps/fz_http/test/fz_http_web/live/device_live/unprivileged/show_test.exs rename to apps/web/test/fz_http_web/live/device_live/unprivileged/show_test.exs diff --git a/apps/fz_http/test/fz_http_web/live/mfa_live/auth_test.exs b/apps/web/test/fz_http_web/live/mfa_live/auth_test.exs similarity index 100% rename from apps/fz_http/test/fz_http_web/live/mfa_live/auth_test.exs rename to apps/web/test/fz_http_web/live/mfa_live/auth_test.exs diff --git a/apps/fz_http/test/fz_http_web/live/notifications_live/badge_test.exs b/apps/web/test/fz_http_web/live/notifications_live/badge_test.exs similarity index 100% rename from apps/fz_http/test/fz_http_web/live/notifications_live/badge_test.exs rename to apps/web/test/fz_http_web/live/notifications_live/badge_test.exs diff --git a/apps/fz_http/test/fz_http_web/live/notifications_live/index_test.exs b/apps/web/test/fz_http_web/live/notifications_live/index_test.exs similarity index 100% rename from apps/fz_http/test/fz_http_web/live/notifications_live/index_test.exs rename to apps/web/test/fz_http_web/live/notifications_live/index_test.exs diff --git a/apps/fz_http/test/fz_http_web/live/rule_live/index_test.exs b/apps/web/test/fz_http_web/live/rule_live/index_test.exs similarity index 100% rename from apps/fz_http/test/fz_http_web/live/rule_live/index_test.exs rename to apps/web/test/fz_http_web/live/rule_live/index_test.exs diff --git a/apps/fz_http/test/fz_http_web/live/setting_live/account_test.exs b/apps/web/test/fz_http_web/live/setting_live/account_test.exs similarity index 100% rename from apps/fz_http/test/fz_http_web/live/setting_live/account_test.exs rename to apps/web/test/fz_http_web/live/setting_live/account_test.exs diff --git a/apps/fz_http/test/fz_http_web/live/setting_live/client_defaults_test.exs b/apps/web/test/fz_http_web/live/setting_live/client_defaults_test.exs similarity index 100% rename from apps/fz_http/test/fz_http_web/live/setting_live/client_defaults_test.exs rename to apps/web/test/fz_http_web/live/setting_live/client_defaults_test.exs diff --git a/apps/fz_http/test/fz_http_web/live/setting_live/customization_test.exs b/apps/web/test/fz_http_web/live/setting_live/customization_test.exs similarity index 100% rename from apps/fz_http/test/fz_http_web/live/setting_live/customization_test.exs rename to apps/web/test/fz_http_web/live/setting_live/customization_test.exs diff --git a/apps/fz_http/test/fz_http_web/live/setting_live/security_test.exs b/apps/web/test/fz_http_web/live/setting_live/security_test.exs similarity index 100% rename from apps/fz_http/test/fz_http_web/live/setting_live/security_test.exs rename to apps/web/test/fz_http_web/live/setting_live/security_test.exs diff --git a/apps/fz_http/test/fz_http_web/live/setting_live/unprivileged/account_test.exs b/apps/web/test/fz_http_web/live/setting_live/unprivileged/account_test.exs similarity index 100% rename from apps/fz_http/test/fz_http_web/live/setting_live/unprivileged/account_test.exs rename to apps/web/test/fz_http_web/live/setting_live/unprivileged/account_test.exs diff --git a/apps/fz_http/test/fz_http_web/live/user_live/index_test.exs b/apps/web/test/fz_http_web/live/user_live/index_test.exs similarity index 100% rename from apps/fz_http/test/fz_http_web/live/user_live/index_test.exs rename to apps/web/test/fz_http_web/live/user_live/index_test.exs diff --git a/apps/fz_http/test/fz_http_web/live/user_live/show_test.exs b/apps/web/test/fz_http_web/live/user_live/show_test.exs similarity index 100% rename from apps/fz_http/test/fz_http_web/live/user_live/show_test.exs rename to apps/web/test/fz_http_web/live/user_live/show_test.exs diff --git a/apps/fz_http/test/fz_http_web/live/user_live/vpn_connection_component_test.exs b/apps/web/test/fz_http_web/live/user_live/vpn_connection_component_test.exs similarity index 100% rename from apps/fz_http/test/fz_http_web/live/user_live/vpn_connection_component_test.exs rename to apps/web/test/fz_http_web/live/user_live/vpn_connection_component_test.exs diff --git a/apps/fz_http/test/fz_http_web/live/user_live/vpn_status_component_test.exs b/apps/web/test/fz_http_web/live/user_live/vpn_status_component_test.exs similarity index 100% rename from apps/fz_http/test/fz_http_web/live/user_live/vpn_status_component_test.exs rename to apps/web/test/fz_http_web/live/user_live/vpn_status_component_test.exs diff --git a/apps/fz_http/test/fz_http_web/mailer_test.exs b/apps/web/test/fz_http_web/mailer_test.exs similarity index 100% rename from apps/fz_http/test/fz_http_web/mailer_test.exs rename to apps/web/test/fz_http_web/mailer_test.exs diff --git a/apps/fz_http/test/fz_http_web/mailer_test/sample_email/test_heex.html.heex b/apps/web/test/fz_http_web/mailer_test/sample_email/test_heex.html.heex similarity index 100% rename from apps/fz_http/test/fz_http_web/mailer_test/sample_email/test_heex.html.heex rename to apps/web/test/fz_http_web/mailer_test/sample_email/test_heex.html.heex diff --git a/apps/fz_http/test/fz_http_web/mailer_test/sample_email/test_multipart.html.eex b/apps/web/test/fz_http_web/mailer_test/sample_email/test_multipart.html.eex similarity index 100% rename from apps/fz_http/test/fz_http_web/mailer_test/sample_email/test_multipart.html.eex rename to apps/web/test/fz_http_web/mailer_test/sample_email/test_multipart.html.eex diff --git a/apps/fz_http/test/fz_http_web/mailer_test/sample_email/test_multipart.text.eex b/apps/web/test/fz_http_web/mailer_test/sample_email/test_multipart.text.eex similarity index 100% rename from apps/fz_http/test/fz_http_web/mailer_test/sample_email/test_multipart.text.eex rename to apps/web/test/fz_http_web/mailer_test/sample_email/test_multipart.text.eex diff --git a/apps/fz_http/test/fz_http_web/plug/path_prefix_test.exs b/apps/web/test/fz_http_web/plug/path_prefix_test.exs similarity index 100% rename from apps/fz_http/test/fz_http_web/plug/path_prefix_test.exs rename to apps/web/test/fz_http_web/plug/path_prefix_test.exs diff --git a/apps/fz_http/test/fz_http_web/user_from_auth_test.exs b/apps/web/test/fz_http_web/user_from_auth_test.exs similarity index 100% rename from apps/fz_http/test/fz_http_web/user_from_auth_test.exs rename to apps/web/test/fz_http_web/user_from_auth_test.exs diff --git a/apps/fz_http/test/fz_http_web/views/error_view_test.exs b/apps/web/test/fz_http_web/views/error_view_test.exs similarity index 100% rename from apps/fz_http/test/fz_http_web/views/error_view_test.exs rename to apps/web/test/fz_http_web/views/error_view_test.exs diff --git a/apps/fz_http/test/fz_http_web/views/shared_view_test.exs b/apps/web/test/fz_http_web/views/shared_view_test.exs similarity index 100% rename from apps/fz_http/test/fz_http_web/views/shared_view_test.exs rename to apps/web/test/fz_http_web/views/shared_view_test.exs diff --git a/apps/fz_http/test/support/acceptance_case.ex b/apps/web/test/support/acceptance_case.ex similarity index 100% rename from apps/fz_http/test/support/acceptance_case.ex rename to apps/web/test/support/acceptance_case.ex diff --git a/apps/fz_http/test/support/acceptance_case/auth.ex b/apps/web/test/support/acceptance_case/auth.ex similarity index 100% rename from apps/fz_http/test/support/acceptance_case/auth.ex rename to apps/web/test/support/acceptance_case/auth.ex diff --git a/apps/fz_http/test/support/acceptance_case/simple_saml.ex b/apps/web/test/support/acceptance_case/simple_saml.ex similarity index 100% rename from apps/fz_http/test/support/acceptance_case/simple_saml.ex rename to apps/web/test/support/acceptance_case/simple_saml.ex diff --git a/apps/fz_http/test/support/acceptance_case/vault.ex b/apps/web/test/support/acceptance_case/vault.ex similarity index 100% rename from apps/fz_http/test/support/acceptance_case/vault.ex rename to apps/web/test/support/acceptance_case/vault.ex diff --git a/apps/fz_http/test/support/api_case.ex b/apps/web/test/support/api_case.ex similarity index 100% rename from apps/fz_http/test/support/api_case.ex rename to apps/web/test/support/api_case.ex diff --git a/apps/fz_http/test/support/case_template.ex b/apps/web/test/support/case_template.ex similarity index 100% rename from apps/fz_http/test/support/case_template.ex rename to apps/web/test/support/case_template.ex diff --git a/apps/fz_http/test/support/channel_case.ex b/apps/web/test/support/channel_case.ex similarity index 100% rename from apps/fz_http/test/support/channel_case.ex rename to apps/web/test/support/channel_case.ex diff --git a/apps/fz_http/test/support/conn_case.ex b/apps/web/test/support/conn_case.ex similarity index 100% rename from apps/fz_http/test/support/conn_case.ex rename to apps/web/test/support/conn_case.ex diff --git a/apps/fz_http/test/support/data_case.ex b/apps/web/test/support/data_case.ex similarity index 100% rename from apps/fz_http/test/support/data_case.ex rename to apps/web/test/support/data_case.ex diff --git a/apps/fz_http/test/support/docs_generator.ex b/apps/web/test/support/docs_generator.ex similarity index 100% rename from apps/fz_http/test/support/docs_generator.ex rename to apps/web/test/support/docs_generator.ex diff --git a/apps/fz_http/test/support/fixtures/api_tokens_fixtures.ex b/apps/web/test/support/fixtures/api_tokens_fixtures.ex similarity index 100% rename from apps/fz_http/test/support/fixtures/api_tokens_fixtures.ex rename to apps/web/test/support/fixtures/api_tokens_fixtures.ex diff --git a/apps/fz_http/test/support/fixtures/config_fixtures.ex b/apps/web/test/support/fixtures/config_fixtures.ex similarity index 100% rename from apps/fz_http/test/support/fixtures/config_fixtures.ex rename to apps/web/test/support/fixtures/config_fixtures.ex diff --git a/apps/fz_http/test/support/fixtures/connectivity_checks_fixtures.ex b/apps/web/test/support/fixtures/connectivity_checks_fixtures.ex similarity index 100% rename from apps/fz_http/test/support/fixtures/connectivity_checks_fixtures.ex rename to apps/web/test/support/fixtures/connectivity_checks_fixtures.ex diff --git a/apps/fz_http/test/support/fixtures/devices_fixtures.ex b/apps/web/test/support/fixtures/devices_fixtures.ex similarity index 100% rename from apps/fz_http/test/support/fixtures/devices_fixtures.ex rename to apps/web/test/support/fixtures/devices_fixtures.ex diff --git a/apps/fz_http/test/support/fixtures/mfa_fixtures.ex b/apps/web/test/support/fixtures/mfa_fixtures.ex similarity index 100% rename from apps/fz_http/test/support/fixtures/mfa_fixtures.ex rename to apps/web/test/support/fixtures/mfa_fixtures.ex diff --git a/apps/fz_http/test/support/fixtures/notifications_fixtures.ex b/apps/web/test/support/fixtures/notifications_fixtures.ex similarity index 100% rename from apps/fz_http/test/support/fixtures/notifications_fixtures.ex rename to apps/web/test/support/fixtures/notifications_fixtures.ex diff --git a/apps/fz_http/test/support/fixtures/rules_fixtures.ex b/apps/web/test/support/fixtures/rules_fixtures.ex similarity index 100% rename from apps/fz_http/test/support/fixtures/rules_fixtures.ex rename to apps/web/test/support/fixtures/rules_fixtures.ex diff --git a/apps/fz_http/test/support/fixtures/subject_fixtures.ex b/apps/web/test/support/fixtures/subject_fixtures.ex similarity index 100% rename from apps/fz_http/test/support/fixtures/subject_fixtures.ex rename to apps/web/test/support/fixtures/subject_fixtures.ex diff --git a/apps/fz_http/test/support/fixtures/users_fixtures.ex b/apps/web/test/support/fixtures/users_fixtures.ex similarity index 100% rename from apps/fz_http/test/support/fixtures/users_fixtures.ex rename to apps/web/test/support/fixtures/users_fixtures.ex diff --git a/apps/fz_http/test/support/mailer_case.ex b/apps/web/test/support/mailer_case.ex similarity index 100% rename from apps/fz_http/test/support/mailer_case.ex rename to apps/web/test/support/mailer_case.ex diff --git a/apps/fz_http/test/support/mailer_test_adapter.ex b/apps/web/test/support/mailer_test_adapter.ex similarity index 100% rename from apps/fz_http/test/support/mailer_test_adapter.ex rename to apps/web/test/support/mailer_test_adapter.ex diff --git a/apps/fz_http/test/support/test_helpers.ex b/apps/web/test/support/test_helpers.ex similarity index 100% rename from apps/fz_http/test/support/test_helpers.ex rename to apps/web/test/support/test_helpers.ex diff --git a/apps/fz_http/test/test_helper.exs b/apps/web/test/test_helper.exs similarity index 100% rename from apps/fz_http/test/test_helper.exs rename to apps/web/test/test_helper.exs diff --git a/asyncapi.yml b/asyncapi.yml deleted file mode 100644 index 6b1335374..000000000 --- a/asyncapi.yml +++ /dev/null @@ -1,265 +0,0 @@ -# -# Copy the contents of this file to studio.asyncapi.com to view the generated -# output. -# -# TODO: Add this to docs when repo goes public. - -asyncapi: "2.5.0" - -tags: - - name: gateway - description: Realtime API for Firezone Gateway - -info: - license: - name: Apache 2.0 - url: http://www.apache.org/licenses/LICENSE-2.0.html - title: Firezone Realtime API - version: "1.0.0" - contact: - name: Firezone - url: https://www.firezone.dev/ - email: async-api@firezone.dev - description: | - Realtime API documentation for Firezone's control plane. - -externalDocs: - url: https://docs.firezone.dev/ - -servers: - public: - url: wss://firezone.example.com - protocol: wss - -channels: - /v1/gateway-ctl: - subscribe: - operationId: subscribe - summary: Receive control commands for a connected gateway. - description: | - The gateway WebSocket channel. - message: - oneOf: - - $ref: "#/components/messages/add_rule" - - $ref: "#/components/messages/delete_rule" - - $ref: "#/components/messages/add_peer" - - $ref: "#/components/messages/delete_peer" - - $ref: "#/components/messages/init" - -components: - messages: - add_rule: - summary: Adds an egress rule to the Gateway. - payload: - $ref: "#/components/schemas/add_rule" - examples: - - payload: - add_rule: - dst: 0.0.0.0/8 - port_range: - range_start: 80 - range_end: 81 - protocol: tcp - user_uuid: 3118158c-29cb-47d6-adbf-5edd15f1af17 - delete_rule: - summary: Removes an egress rule from the Gateway. - payload: - $ref: "#/components/schemas/delete_rule" - examples: - - payload: - delete_rule: - dst: 0.0.0.0/8 - port_range: - range_start: 80 - range_end: 81 - protocol: tcp - user_uuid: 3118158c-29cb-47d6-adbf-5edd15f1af17 - add_peer: - summary: Adds a peer to the receiver's WireGuard configuration. - payload: - $ref: "#/components/schemas/add_peer" - examples: - - name: Gateway example - payload: - add_peer: - public_key: AxVaJsPC1FSrOM5RpEXg4umTKMxkHkgMy1fl7t1xNyw= - preshared_key: LZBIpoLNCkIe56cPM+5pY/hP2pu7SGARvQZEThmuPYM= - user_uuid: 3118158c-29cb-47d6-adbf-5edd15f1af17 - allowed_ips: - - 100.64.11.22/32 - - delete_peer: - summary: Removes a peer from the receiver's WireGuard configuration. - payload: - $ref: "#/components/schemas/delete_peer" - examples: - - name: Gateway example - payload: - delete_peer: - public_key: AxVaJsPC1FSrOM5RpEXg4umTKMxkHkgMy1fl7t1xNyw= - - init: - summary: A control command to initialize the client with initial config - description: | - This command initializes a client with its configuration after successfully connecting the WebSocket. - payload: - $ref: "#/components/schemas/init" - examples: - - name: Gateway example - payload: - init: - default_action: deny - interface: - address: - - 100.64.11.22/10 - mtu: 1280 - peers: - - allowed_ips: - - 100.64.11.22/32 - public_key: AxVaJsPC1FSrOM5RpEXg4umTKMxkHkgMy1fl7t1xNyw= - preshared_key: LZBIpoLNCkIe56cPM+5pY/hP2pu7SGARvQZEThmuPYM= - user_uuid: 3118158c-29cb-47d6-adbf-5edd15f1af17 - - schemas: - init: - required: - - init - summary: Gateway initialization - description: | - This message indicates the gateway should reconfigure itself with the contained configuration. - properties: - init: - type: object - required: - - peers - - interface - properties: - default_action: - summary: The default action taken by the gateway for the egress firewall. - type: string - enum: - - deny - - allow - peers: - type: array - items: - $ref: "#/components/schemas/peer" - interface: - required: - - mtu - - address - type: object - properties: - dns: - type: array - items: - type: string - mtu: - type: integer - listen_port: - type: integer - address: - type: array - description: The IPv4 and/or IPv6 address(es) to set on the interface. - items: - type: string - - add_peer: - required: - - add_peer - summary: Add a Peer to the WireGuard configuration. - properties: - add_peer: - $ref: "#/components/schemas/peer" - - delete_peer: - summary: Remove a Peer from the WireGuard configuration. - required: - - delete_peer - properties: - delete_peer: - type: object - required: - - public_key - properties: - public_key: - type: string - - add_rule: - type: object - required: - - add_rule - summary: Add rule - description: | - A JSON representation of the rule specification. - properties: - add_rule: - $ref: "#/components/schemas/rule" - - delete_rule: - required: - - delete_rule - summary: Delete Rule - type: object - properties: - delete_rule: - $ref: "#/components/schemas/rule" - - rule: - type: object - description: | - A JSON representation of the rule specification. - required: - - dst - properties: - dst: - type: string - user_uuid: - type: string - port_range: - $ref: "#/components/schemas/port_range" - - peer: - type: object - required: - - public_key - - preshared_key - - allowed_ips - properties: - user_uuid: - type: string - summary: Optional user_uuid used by the Gateway to group this peer's egress rules. - endpoint: - type: string - persistent_keepalive: - type: integer - public_key: - type: string - preshared_key: - type: string - allowed_ips: - type: array - items: - type: string - description: | - The IPs addresses to send through the tunnel. - For connected end-user devices, this will always be a /32 and/or /128. - For static tunnels to other gateways (site to site configuration) this can include multiple CIDRs. - - port_range: - type: object - required: - - range_start - - range_end - properties: - range_start: - type: number - summary: starting port of the range, inclusive. - range_end: - type: number - summary: ending port of the range, inclusive. - protocol: - type: string - enum: - - tcp - - udp diff --git a/config/dev.exs b/config/dev.exs index 501d043ed..9eacfdcaf 100644 --- a/config/dev.exs +++ b/config/dev.exs @@ -13,14 +13,14 @@ config :fz_http, FzHttpWeb.Endpoint, code_reloader: true, check_origin: ["//127.0.0.1", "//localhost"], watchers: [ - node: ["esbuild.js", "dev", cd: Path.expand("../apps/fz_http/assets", __DIR__)] + node: ["esbuild.js", "dev", cd: Path.expand("../apps/web/assets", __DIR__)] ], live_reload: [ patterns: [ - ~r"apps/fz_http/priv/static/.*(js|css|png|jpeg|jpg|gif|svg)$", - ~r"apps/fz_http/priv/gettext/.*(po)$", - ~r"apps/fz_http/lib/fz_http_web/(live|views)/.*(ex)$", - ~r"apps/fz_http/lib/fz_http_web/templates/.*(eex)$" + ~r"apps/web/priv/static/.*(js|css|png|jpeg|jpg|gif|svg)$", + ~r"apps/web/priv/gettext/.*(po)$", + ~r"apps/web/lib/web_web/(live|views)/.*(ex)$", + ~r"apps/web/lib/web_web/templates/.*(eex)$" ] ] diff --git a/docker-compose.yml b/docker-compose.yml index 75c0780c6..cdba0c378 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -35,7 +35,7 @@ services: # from the local project. This is needed when the Docker Host platform # doesn't match the platform under which Docker Engine is running. e.g. # WSL, Docker for Mac, etc. - - /var/app/apps/fz_http/assets/node_modules + - /var/app/apps/web/assets/node_modules ports: - 51820:51820/udp environment: diff --git a/mix.exs b/mix.exs index 0cfa4b5bd..b1a03d242 100644 --- a/mix.exs +++ b/mix.exs @@ -24,7 +24,7 @@ defmodule FirezoneUmbrella.MixProject do "coveralls.html": :test ], docs: [ - logo: "apps/fz_http/assets/static/images/logo.svg", + logo: "apps/web/assets/static/images/logo.svg", extras: ["README.md", "SECURITY.md", "CONTRIBUTING.md"] ], deps: deps(), @@ -38,9 +38,9 @@ defmodule FirezoneUmbrella.MixProject do include_executables_for: [:unix], validate_compile_env: false, applications: [ - fz_http: :permanent, - fz_wall: :permanent, - fz_vpn: :permanent + domain: :permanent, + web: :permanent, + api: :permanent ], cookie: System.get_env("ERL_COOKIE") ] @@ -73,7 +73,7 @@ defmodule FirezoneUmbrella.MixProject do defp aliases do [ - "ecto.seed": ["ecto.create", "ecto.migrate", "run apps/fz_http/priv/repo/seeds.exs"], + "ecto.seed": ["ecto.create", "ecto.migrate", "run apps/web/priv/repo/seeds.exs"], "ecto.setup": ["ecto.create", "ecto.migrate"], "ecto.reset": ["ecto.drop", "ecto.setup"], test: ["ecto.create --quiet", "ecto.migrate", "test"], diff --git a/omnibus/.gitignore b/omnibus/.gitignore deleted file mode 100644 index 3a1b0067a..000000000 --- a/omnibus/.gitignore +++ /dev/null @@ -1,11 +0,0 @@ -*.gem -.bundle -.kitchen/ -.kitchen.local.yml -vendor/bundle -pkg/* -.vagrant -bin/* -files/**/cache/ -vendor/cookbooks -local/ diff --git a/omnibus/.kitchen.yml b/omnibus/.kitchen.yml deleted file mode 100644 index 2317dc437..000000000 --- a/omnibus/.kitchen.yml +++ /dev/null @@ -1,41 +0,0 @@ -driver: - name: vagrant - forward_agent: yes - customize: - cpus: 2 - memory: 2048 - synced_folders: - - ['.', '/home/vagrant/firezone'] - -provisioner: - name: chef_zero - -platforms: - - name: centos-6 - run_list: yum-epel::default - - name: centos-7 - run_list: yum-epel::default - - name: debian-8 - run_list: apt::default - - name: debian-9 - run_list: apt::default - - name: freebsd-10 - run_list: freebsd::portsnap - - name: freebsd-11 - run_list: freebsd::portsnap - - name: ubuntu-14.04 - run_list: apt::default - - name: ubuntu-16.04 - run_list: apt::default - - name: ubuntu-18.04 - run_list: apt::default - -suites: - - name: default - run_list: omnibus::default - attributes: - omnibus: - build_user: vagrant - build_user_group: vagrant - build_user_password: vagrant - install_dir: /opt/firezone diff --git a/omnibus/Berksfile b/omnibus/Berksfile deleted file mode 100644 index efe863635..000000000 --- a/omnibus/Berksfile +++ /dev/null @@ -1,14 +0,0 @@ -# frozen_string_literal: true - -source 'https://supermarket.chef.io' - -cookbook 'omnibus' - -# Uncomment to use the latest version of the Omnibus cookbook from GitHub -# cookbook 'omnibus', github: 'chef-cookbooks/omnibus' - -group :integration do - cookbook 'apt', '~> 2.8' - cookbook 'freebsd', '~> 0.3' - cookbook 'yum-epel', '~> 0.6' -end diff --git a/omnibus/Gemfile b/omnibus/Gemfile deleted file mode 100644 index e2f56cb5b..000000000 --- a/omnibus/Gemfile +++ /dev/null @@ -1,26 +0,0 @@ -# frozen_string_literal: true - -source 'https://rubygems.org' - -# Install omnibus -gem 'chef', '~> 17.10.0' -gem 'omnibus', '~> 8.3.2' - -# Use Chef"s software definitions. It is recommended that you write your own -# software definitions, but you can clone/fork Chef"s to get you started. -# gem "omnibus-software", github: "chef/omnibus-software" - -# This development group is installed by default when you run `bundle install`, -# but if you are using Omnibus in a CI-based infrastructure, you do not need -# the Test Kitchen-based build lab. You can skip these unnecessary dependencies -# by running `bundle install --without development` to speed up build times. -group :development do - # Use Berkshelf for resolving cookbook dependencies - gem 'berkshelf' - - gem 'rubocop' - - # Use Test Kitchen with Vagrant for converging the build environment - gem 'kitchen-vagrant' - gem 'test-kitchen' -end diff --git a/omnibus/Gemfile.lock b/omnibus/Gemfile.lock deleted file mode 100644 index fe7b72a9b..000000000 --- a/omnibus/Gemfile.lock +++ /dev/null @@ -1,390 +0,0 @@ -GEM - remote: https://rubygems.org/ - specs: - addressable (2.8.1) - public_suffix (>= 2.0.2, < 6.0) - ast (2.4.2) - awesome_print (1.9.2) - aws-eventstream (1.2.0) - aws-partitions (1.624.0) - aws-sdk-core (3.138.0) - aws-eventstream (~> 1, >= 1.0.2) - aws-partitions (~> 1, >= 1.525.0) - aws-sigv4 (~> 1.1) - jmespath (~> 1, >= 1.6.1) - aws-sdk-kms (1.58.0) - aws-sdk-core (~> 3, >= 3.127.0) - aws-sigv4 (~> 1.1) - aws-sdk-s3 (1.114.0) - aws-sdk-core (~> 3, >= 3.127.0) - aws-sdk-kms (~> 1) - aws-sigv4 (~> 1.4) - aws-sdk-secretsmanager (1.65.0) - aws-sdk-core (~> 3, >= 3.127.0) - aws-sigv4 (~> 1.1) - aws-sigv4 (1.5.1) - aws-eventstream (~> 1, >= 1.0.2) - bcrypt_pbkdf (1.1.0) - berkshelf (8.0.2) - chef (>= 15.7.32) - chef-config - cleanroom (~> 1.0) - concurrent-ruby (~> 1.0) - minitar (>= 0.6) - mixlib-archive (>= 1.1.4, < 2.0) - mixlib-config (>= 2.2.5) - mixlib-shellout (>= 2.0, < 4.0) - octokit (~> 4.0) - retryable (>= 2.0, < 4.0) - solve (~> 4.0) - thor (>= 0.20) - builder (3.2.4) - chef (17.10.0) - addressable - aws-sdk-s3 (~> 1.91) - aws-sdk-secretsmanager (~> 1.46) - chef-config (= 17.10.0) - chef-utils (= 17.10.0) - chef-vault - chef-zero (>= 14.0.11) - corefoundation (~> 0.3.4) - diff-lcs (>= 1.2.4, < 1.6.0, != 1.4.0) - erubis (~> 2.7) - ffi (>= 1.5.0) - ffi-libarchive (~> 1.0, >= 1.0.3) - ffi-yajl (~> 2.2) - iniparse (~> 1.4) - inspec-core (~> 4.23) - license-acceptance (>= 1.0.5, < 3) - mixlib-archive (>= 0.4, < 2.0) - mixlib-authentication (>= 2.1, < 4) - mixlib-cli (>= 2.1.1, < 3.0) - mixlib-log (>= 2.0.3, < 4.0) - mixlib-shellout (>= 3.1.1, < 4.0) - net-sftp (>= 2.1.2, < 4.0) - ohai (~> 17.0) - plist (~> 3.2) - proxifier (~> 1.0) - syslog-logger (~> 1.6) - train-core (~> 3.2, >= 3.2.28) - train-winrm (>= 0.2.5) - uuidtools (>= 2.1.5, < 3.0) - vault (~> 0.16) - chef-cleanroom (1.0.5) - chef-config (17.10.0) - addressable - chef-utils (= 17.10.0) - fuzzyurl - mixlib-config (>= 2.2.12, < 4.0) - mixlib-shellout (>= 2.0, < 4.0) - tomlrb (~> 1.2) - chef-telemetry (1.1.1) - chef-config - concurrent-ruby (~> 1.0) - chef-utils (17.10.0) - concurrent-ruby - chef-vault (4.1.10) - chef-zero (15.0.11) - ffi-yajl (~> 2.2) - hashie (>= 2.0, < 5.0) - mixlib-log (>= 2.0, < 4.0) - rack (~> 2.0, >= 2.0.6) - uuidtools (~> 2.1) - webrick - citrus (3.0.2) - cleanroom (1.0.0) - coderay (1.1.3) - concurrent-ruby (1.1.10) - contracts (0.16.1) - corefoundation (0.3.13) - ffi (>= 1.15.0) - diff-lcs (1.5.0) - ed25519 (1.3.0) - erubi (1.11.0) - erubis (2.7.0) - faraday (1.4.3) - faraday-em_http (~> 1.0) - faraday-em_synchrony (~> 1.0) - faraday-excon (~> 1.1) - faraday-net_http (~> 1.0) - faraday-net_http_persistent (~> 1.1) - multipart-post (>= 1.2, < 3) - ruby2_keywords (>= 0.0.4) - faraday-em_http (1.0.0) - faraday-em_synchrony (1.0.0) - faraday-excon (1.1.0) - faraday-net_http (1.0.1) - faraday-net_http_persistent (1.2.0) - faraday_middleware (1.2.0) - faraday (~> 1.0) - ffi (1.15.5) - ffi-libarchive (1.1.3) - ffi (~> 1.0) - ffi-yajl (2.4.0) - libyajl2 (>= 1.2) - fuzzyurl (0.9.0) - gssapi (1.3.1) - ffi (>= 1.0.1) - gyoku (1.4.0) - builder (>= 2.1.2) - rexml (~> 3.0) - hashie (4.1.0) - httpclient (2.8.3) - iniparse (1.5.0) - inspec-core (4.56.20) - addressable (~> 2.4) - chef-telemetry (~> 1.0, >= 1.0.8) - faraday (>= 0.9.0, < 1.5) - faraday_middleware (~> 1.0) - hashie (>= 3.4, < 5.0) - license-acceptance (>= 0.2.13, < 3.0) - method_source (>= 0.8, < 2.0) - mixlib-log (~> 3.0) - multipart-post (~> 2.0) - parallel (~> 1.9) - parslet (>= 1.5, < 2.0) - pry (~> 0.13) - rspec (>= 3.9, <= 3.11) - rspec-its (~> 1.2) - rubyzip (>= 1.2.2, < 3.0) - semverse (~> 3.0) - sslshake (~> 1.2) - thor (>= 0.20, < 2.0) - tomlrb (>= 1.2, < 2.1) - train-core (~> 3.0) - tty-prompt (~> 0.17) - tty-table (~> 0.10) - iostruct (0.0.4) - ipaddress (0.8.3) - jmespath (1.6.1) - json (2.6.2) - kitchen-vagrant (1.12.1) - test-kitchen (>= 1.4, < 4) - libyajl2 (2.1.0) - license-acceptance (2.1.13) - pastel (~> 0.7) - tomlrb (>= 1.2, < 3.0) - tty-box (~> 0.6) - tty-prompt (~> 0.20) - license_scout (1.3.2) - ffi-yajl (~> 2.2) - mixlib-shellout (>= 2.2, < 4.0) - toml-rb (>= 1, < 3) - little-plugger (1.1.4) - logging (2.3.1) - little-plugger (~> 1.1) - multi_json (~> 1.14) - method_source (1.0.0) - minitar (0.9) - mixlib-archive (1.1.7) - mixlib-log - mixlib-authentication (3.0.10) - mixlib-cli (2.1.8) - mixlib-config (3.0.27) - tomlrb - mixlib-install (3.12.19) - mixlib-shellout - mixlib-versioning - thor - mixlib-log (3.0.9) - mixlib-shellout (3.2.7) - chef-utils - mixlib-versioning (1.2.12) - molinillo (0.8.0) - multi_json (1.15.0) - multipart-post (2.2.3) - net-scp (3.0.0) - net-ssh (>= 2.6.5, < 7.0.0) - net-sftp (3.0.0) - net-ssh (>= 5.0.0, < 7.0.0) - net-ssh (6.1.0) - net-ssh-gateway (2.0.0) - net-ssh (>= 4.0.0) - nori (2.6.0) - octokit (4.25.1) - faraday (>= 1, < 3) - sawyer (~> 0.9) - ohai (17.9.0) - chef-config (>= 14.12, < 18) - chef-utils (>= 16.0, < 18) - ffi (~> 1.9) - ffi-yajl (~> 2.2) - ipaddress - mixlib-cli (>= 1.7.0) - mixlib-config (>= 2.0, < 4.0) - mixlib-log (>= 2.0.1, < 4.0) - mixlib-shellout (~> 3.2, >= 3.2.5) - plist (~> 3.1) - train-core - wmi-lite (~> 1.0) - omnibus (8.3.2) - aws-sdk-s3 (~> 1) - chef-cleanroom (~> 1.0) - chef-utils (>= 15.4) - contracts (>= 0.16.0, < 0.17.0) - ffi-yajl (~> 2.2) - license_scout (~> 1.0) - mixlib-shellout (>= 2.0, < 4.0) - mixlib-versioning - ohai (>= 15, < 18) - pedump - ruby-progressbar (~> 1.7) - thor (>= 0.18, < 2.0) - parallel (1.22.1) - parser (3.1.2.1) - ast (~> 2.4.1) - parslet (1.8.2) - pastel (0.8.0) - tty-color (~> 0.5) - pedump (0.6.5) - awesome_print - iostruct (>= 0.0.4) - multipart-post (>= 2.0.0) - rainbow - zhexdump (>= 0.0.2) - plist (3.6.0) - proxifier (1.0.3) - pry (0.14.1) - coderay (~> 1.1) - method_source (~> 1.0) - public_suffix (5.0.0) - rack (2.2.4) - rainbow (3.1.1) - regexp_parser (2.5.0) - retryable (3.0.5) - rexml (3.2.5) - rspec (3.11.0) - rspec-core (~> 3.11.0) - rspec-expectations (~> 3.11.0) - rspec-mocks (~> 3.11.0) - rspec-core (3.11.0) - rspec-support (~> 3.11.0) - rspec-expectations (3.11.0) - diff-lcs (>= 1.2.0, < 2.0) - rspec-support (~> 3.11.0) - rspec-its (1.3.0) - rspec-core (>= 3.0.0) - rspec-expectations (>= 3.0.0) - rspec-mocks (3.11.1) - diff-lcs (>= 1.2.0, < 2.0) - rspec-support (~> 3.11.0) - rspec-support (3.11.0) - rubocop (1.36.0) - json (~> 2.3) - parallel (~> 1.10) - parser (>= 3.1.2.1) - rainbow (>= 2.2.2, < 4.0) - regexp_parser (>= 1.8, < 3.0) - rexml (>= 3.2.5, < 4.0) - rubocop-ast (>= 1.20.1, < 2.0) - ruby-progressbar (~> 1.7) - unicode-display_width (>= 1.4.0, < 3.0) - rubocop-ast (1.21.0) - parser (>= 3.1.1.0) - ruby-progressbar (1.11.0) - ruby2_keywords (0.0.5) - rubyntlm (0.6.3) - rubyzip (2.3.2) - sawyer (0.9.2) - addressable (>= 2.3.5) - faraday (>= 0.17.3, < 3) - semverse (3.0.2) - solve (4.0.4) - molinillo (~> 0.6) - semverse (>= 1.1, < 4.0) - sslshake (1.3.1) - strings (0.2.1) - strings-ansi (~> 0.2) - unicode-display_width (>= 1.5, < 3.0) - unicode_utils (~> 1.4) - strings-ansi (0.2.0) - syslog-logger (1.6.8) - test-kitchen (3.3.2) - bcrypt_pbkdf (~> 1.0) - chef-utils (>= 16.4.35) - ed25519 (~> 1.2) - license-acceptance (>= 1.0.11, < 3.0) - mixlib-install (~> 3.6) - mixlib-shellout (>= 1.2, < 4.0) - net-scp (>= 1.1, < 4.0) - net-ssh (>= 2.9, < 7.0) - net-ssh-gateway (>= 1.2, < 3.0) - thor (>= 0.19, < 2.0) - winrm (~> 2.0) - winrm-elevated (~> 1.0) - winrm-fs (~> 1.1) - thor (1.2.1) - toml-rb (2.2.0) - citrus (~> 3.0, > 3.0) - tomlrb (1.3.0) - train-core (3.10.1) - addressable (~> 2.5) - ffi (!= 1.13.0) - json (>= 1.8, < 3.0) - mixlib-shellout (>= 2.0, < 4.0) - net-scp (>= 1.2, < 4.0) - net-ssh (>= 2.9, < 7.0) - train-winrm (0.2.13) - winrm (>= 2.3.6, < 3.0) - winrm-elevated (~> 1.2.2) - winrm-fs (~> 1.0) - tty-box (0.7.0) - pastel (~> 0.8) - strings (~> 0.2.0) - tty-cursor (~> 0.7) - tty-color (0.6.0) - tty-cursor (0.7.1) - tty-prompt (0.23.1) - pastel (~> 0.8) - tty-reader (~> 0.8) - tty-reader (0.9.0) - tty-cursor (~> 0.7) - tty-screen (~> 0.8) - wisper (~> 2.0) - tty-screen (0.8.1) - tty-table (0.12.0) - pastel (~> 0.8) - strings (~> 0.2.0) - tty-screen (~> 0.8) - unicode-display_width (2.2.0) - unicode_utils (1.4.0) - uuidtools (2.2.0) - vault (0.17.0) - aws-sigv4 - webrick (1.7.0) - winrm (2.3.6) - builder (>= 2.1.2) - erubi (~> 1.8) - gssapi (~> 1.2) - gyoku (~> 1.0) - httpclient (~> 2.2, >= 2.2.0.2) - logging (>= 1.6.1, < 3.0) - nori (~> 2.0) - rubyntlm (~> 0.6.0, >= 0.6.3) - winrm-elevated (1.2.3) - erubi (~> 1.8) - winrm (~> 2.0) - winrm-fs (~> 1.0) - winrm-fs (1.3.5) - erubi (~> 1.8) - logging (>= 1.6.1, < 3.0) - rubyzip (~> 2.0) - winrm (~> 2.0) - wisper (2.0.1) - wmi-lite (1.0.7) - zhexdump (0.0.2) - -PLATFORMS - arm64-darwin-20 - ruby - -DEPENDENCIES - berkshelf - chef (~> 17.10.0) - kitchen-vagrant - omnibus (~> 8.3.2) - rubocop - test-kitchen - -BUNDLED WITH - 2.3.14 diff --git a/omnibus/README.md b/omnibus/README.md deleted file mode 100644 index ab90b748d..000000000 --- a/omnibus/README.md +++ /dev/null @@ -1,124 +0,0 @@ -firezone Omnibus project -======================== -This project creates full-stack platform-specific packages for -`firezone`! - -Installation ------------- -You must have a sane Ruby 2.0.0+ environment with Bundler installed. Ensure all -the required gems are installed: - -```shell -$ bundle install --binstubs -``` - -Usage ------ -### Build - -You create a platform-specific package using the `build project` command: - -```shell -$ bin/omnibus build firezone -``` - -The platform/architecture type of the package created will match the platform -where the `build project` command is invoked. For example, running this command -on a MacBook Pro will generate a Mac OS X package. After the build completes -packages will be available in the `pkg/` folder. - -### Clean - -You can clean up all temporary files generated during the build process with -the `clean` command: - -```shell -$ bin/omnibus clean firezone -``` - -Adding the `--purge` purge option removes __ALL__ files generated during the -build including the project install directory (`/opt/firezone`) and -the package cache directory (`/var/cache/omnibus/pkg`): - -```shell -$ bin/omnibus clean firezone --purge -``` - -### Publish - -Omnibus has a built-in mechanism for releasing to a variety of "backends", such -as Amazon S3. You must set the proper credentials in your -[`omnibus.rb`](omnibus.rb) config file or specify them via the command line. - -```shell -$ bin/omnibus publish path/to/*.deb --backend s3 -``` - -### Help - -Full help for the Omnibus command line interface can be accessed with the -`help` command: - -```shell -$ bin/omnibus help -``` - -Version Manifest ----------------- - -Git-based software definitions may specify branches as their -default_version. In this case, the exact git revision to use will be -determined at build-time unless a project override (see below) or -external version manifest is used. To generate a version manifest use -the `omnibus manifest` command: - -``` -omnibus manifest PROJECT -l warn -``` - -This will output a JSON-formatted manifest containing the resolved -version of every software definition. - - -Kitchen-based Build Environment -------------------------------- -Every Omnibus project ships with a project-specific -[Berksfile](https://docs.chef.io/berkshelf.html) that will allow you to build -your omnibus projects on all of the platforms listed in the -[`.kitchen.yml`](.kitchen.yml). You can add/remove additional platforms as -needed by changing the list found in the [`.kitchen.yml`](.kitchen.yml) -`platforms` YAML stanza. - -This build environment is designed to get you up-and-running quickly. However, -there is nothing that restricts you from building on other platforms. Simply use -the [omnibus cookbook](https://github.com/chef-cookbooks/omnibus) to setup your -desired platform and execute the build steps listed above. - -The default build environment requires Test Kitchen and VirtualBox for local -development. Test Kitchen also exposes the ability to provision instances using -various cloud providers like AWS, DigitalOcean, or OpenStack. For more -information, please see the [Test Kitchen documentation](https://kitchen.ci/). - -Once you have tweaked your [`.kitchen.yml`](.kitchen.yml) (or -[`.kitchen.local.yml`](.kitchen.local.yml)) to your liking, you can bring up an -individual build environment using the `kitchen` command. - - -```shell -$ bin/kitchen converge ubuntu-1804 -``` - -Then login to the instance and build the project as described in the Usage -section: - -```shell -$ bin/kitchen login ubuntu-1804 -[vagrant@ubuntu...] $ . load-omnibus-toolchain.sh -[vagrant@ubuntu...] $ [ -e .bundle ] && sudo chown -R vagrant:vagrant .bundle -[vagrant@ubuntu...] $ cd firezone # or 'cd firezone/omnibus' if your omnibus project is embedded in your main project -[vagrant@ubuntu...] $ bundle install -[vagrant@ubuntu...] $ bin/omnibus build firezone -``` - -For a complete list of all commands and platforms, run `kitchen list` or -`kitchen help`. diff --git a/omnibus/config/patches/bzip2/aix_makefile.patch b/omnibus/config/patches/bzip2/aix_makefile.patch deleted file mode 100644 index e562728c6..000000000 --- a/omnibus/config/patches/bzip2/aix_makefile.patch +++ /dev/null @@ -1,11 +0,0 @@ ---- bzip2-1.0.8/Makefile-libbz2_so.orig 2019-07-24 10:33:36.184131389 -0400 -+++ bzip2-1.0.8/Makefile-libbz2_so 2019-07-24 10:35:20.564277676 -0400 -@@ -35,7 +35,7 @@ - bzlib.o - - all: $(OBJS) -- $(CC) -shared -Wl,-soname -Wl,libbz2.so.1.0 -o libbz2.so.1.0.8 $(OBJS) -+ $(CC) -qmkshrobj -Wl,-soname -o libbz2.so.1.0.8 $(OBJS) - $(CC) $(CFLAGS) -o bzip2-shared bzip2.c libbz2.so.1.0.8 - rm -f libbz2.so.1.0 - ln -s libbz2.so.1.0.8 libbz2.so.1.0 diff --git a/omnibus/config/patches/bzip2/makefile_no_bins.patch b/omnibus/config/patches/bzip2/makefile_no_bins.patch deleted file mode 100644 index b6cf5e1d5..000000000 --- a/omnibus/config/patches/bzip2/makefile_no_bins.patch +++ /dev/null @@ -1,77 +0,0 @@ ---- bzip2-1.0.8/Makefile-orig 2019-07-13 10:50:05.000000000 -0700 -+++ bzip2-1.0.8/Makefile 2020-08-14 16:35:23.000000000 -0700 -@@ -35,14 +35,11 @@ - decompress.o \ - bzlib.o - --all: libbz2.a bzip2 bzip2recover test -+all: libbz2.a bzip2 test - - bzip2: libbz2.a bzip2.o - $(CC) $(CFLAGS) $(LDFLAGS) -o bzip2 bzip2.o -L. -lbz2 - --bzip2recover: bzip2recover.o -- $(CC) $(CFLAGS) $(LDFLAGS) -o bzip2recover bzip2recover.o -- - libbz2.a: $(OBJS) - rm -f libbz2.a - $(AR) cq libbz2.a $(OBJS) -@@ -69,47 +66,19 @@ - cmp sample3.tst sample3.ref - @cat words3 - --install: bzip2 bzip2recover -+install: bzip2 - if ( test ! -d $(PREFIX)/bin ) ; then mkdir -p $(PREFIX)/bin ; fi - if ( test ! -d $(PREFIX)/lib ) ; then mkdir -p $(PREFIX)/lib ; fi - if ( test ! -d $(PREFIX)/man ) ; then mkdir -p $(PREFIX)/man ; fi - if ( test ! -d $(PREFIX)/man/man1 ) ; then mkdir -p $(PREFIX)/man/man1 ; fi - if ( test ! -d $(PREFIX)/include ) ; then mkdir -p $(PREFIX)/include ; fi -- cp -f bzip2 $(PREFIX)/bin/bzip2 -- cp -f bzip2 $(PREFIX)/bin/bunzip2 -- cp -f bzip2 $(PREFIX)/bin/bzcat -- cp -f bzip2recover $(PREFIX)/bin/bzip2recover -- chmod a+x $(PREFIX)/bin/bzip2 -- chmod a+x $(PREFIX)/bin/bunzip2 -- chmod a+x $(PREFIX)/bin/bzcat -- chmod a+x $(PREFIX)/bin/bzip2recover -- cp -f bzip2.1 $(PREFIX)/man/man1 -- chmod a+r $(PREFIX)/man/man1/bzip2.1 - cp -f bzlib.h $(PREFIX)/include - chmod a+r $(PREFIX)/include/bzlib.h - cp -f libbz2.a $(PREFIX)/lib - chmod a+r $(PREFIX)/lib/libbz2.a -- cp -f bzgrep $(PREFIX)/bin/bzgrep -- ln -s -f $(PREFIX)/bin/bzgrep $(PREFIX)/bin/bzegrep -- ln -s -f $(PREFIX)/bin/bzgrep $(PREFIX)/bin/bzfgrep -- chmod a+x $(PREFIX)/bin/bzgrep -- cp -f bzmore $(PREFIX)/bin/bzmore -- ln -s -f $(PREFIX)/bin/bzmore $(PREFIX)/bin/bzless -- chmod a+x $(PREFIX)/bin/bzmore -- cp -f bzdiff $(PREFIX)/bin/bzdiff -- ln -s -f $(PREFIX)/bin/bzdiff $(PREFIX)/bin/bzcmp -- chmod a+x $(PREFIX)/bin/bzdiff -- cp -f bzgrep.1 bzmore.1 bzdiff.1 $(PREFIX)/man/man1 -- chmod a+r $(PREFIX)/man/man1/bzgrep.1 -- chmod a+r $(PREFIX)/man/man1/bzmore.1 -- chmod a+r $(PREFIX)/man/man1/bzdiff.1 -- echo ".so man1/bzgrep.1" > $(PREFIX)/man/man1/bzegrep.1 -- echo ".so man1/bzgrep.1" > $(PREFIX)/man/man1/bzfgrep.1 -- echo ".so man1/bzmore.1" > $(PREFIX)/man/man1/bzless.1 -- echo ".so man1/bzdiff.1" > $(PREFIX)/man/man1/bzcmp.1 - - clean: -- rm -f *.o libbz2.a bzip2 bzip2recover \ -+ rm -f *.o libbz2.a bzip2 \ - sample1.rb2 sample2.rb2 sample3.rb2 \ - sample1.tst sample2.tst sample3.tst - -@@ -130,8 +99,6 @@ - $(CC) $(CFLAGS) -c bzlib.c - bzip2.o: bzip2.c - $(CC) $(CFLAGS) -c bzip2.c --bzip2recover.o: bzip2recover.c -- $(CC) $(CFLAGS) -c bzip2recover.c - - - distclean: clean diff --git a/omnibus/config/patches/bzip2/makefile_take_env_vars.patch b/omnibus/config/patches/bzip2/makefile_take_env_vars.patch deleted file mode 100644 index 982f03b5a..000000000 --- a/omnibus/config/patches/bzip2/makefile_take_env_vars.patch +++ /dev/null @@ -1,31 +0,0 @@ ---- bzip2-1.0.6/Makefile-orig 2010-09-10 17:46:02.000000000 -0500 -+++ bzip2-1.0.6/Makefile 2013-11-21 13:55:11.000000000 -0600 -@@ -15,13 +15,13 @@ - - SHELL=/bin/sh - - # To assist in cross-compiling --CC=gcc -+CC?=gcc - AR=ar - RANLIB=ranlib --LDFLAGS= -+LDFLAGS+= - --BIGFILES=-D_FILE_OFFSET_BITS=64 -+BIGFILES?=-D_FILE_OFFSET_BITS=64 --CFLAGS=-Wall -Winline -O2 -g $(BIGFILES) -+CFLAGS+=-Wall -Winline -O2 -g $(BIGFILES) - - # Where you want it installed when you do 'make install' - PREFIX=/usr/local ---- bzip2-1.0.6/Makefile-libbz2_so-orig 2017-03-21 19:43:16.706849481 +0000 -+++ bzip2-1.0.6/Makefile-libbz2_so 2017-03-21 19:43:01.187851955 +0000 -@@ -22,7 +22,7 @@ - - - SHELL=/bin/sh --CC=gcc -+CC?=gcc - BIGFILES=-D_FILE_OFFSET_BITS=64 - CFLAGS=-fpic -fPIC -Wall -Winline -O2 -g $(BIGFILES) diff --git a/omnibus/config/patches/bzip2/soname_install_dir.patch b/omnibus/config/patches/bzip2/soname_install_dir.patch deleted file mode 100644 index 599682bff..000000000 --- a/omnibus/config/patches/bzip2/soname_install_dir.patch +++ /dev/null @@ -1,11 +0,0 @@ ---- bzip2-1.0.8/Makefile-libbz2_so.orig 2019-07-24 10:33:36.184131389 -0400 -+++ bzip2-1.0.8/Makefile-libbz2_so 2019-07-24 10:38:15.700843785 -0400 -@@ -35,7 +35,7 @@ - bzlib.o - - all: $(OBJS) -- $(CC) -shared -Wl,-soname -Wl,libbz2.so.1.0 -o libbz2.so.1.0.8 $(OBJS) -+ $(CC) -shared -Wl,-install_name -Wl,libbz2.so.1.0 -o libbz2.so.1.0.8 $(OBJS) - $(CC) $(CFLAGS) -o bzip2-shared bzip2.c libbz2.so.1.0.8 - rm -f libbz2.so.1.0 - ln -s libbz2.so.1.0.8 libbz2.so.1.0 diff --git a/omnibus/config/patches/chef-bin/disable_license_enforce.patch b/omnibus/config/patches/chef-bin/disable_license_enforce.patch deleted file mode 100644 index 2d5f681ef..000000000 --- a/omnibus/config/patches/chef-bin/disable_license_enforce.patch +++ /dev/null @@ -1,10 +0,0 @@ -diff --git a/chef-bin/bin/chef-client b/chef-bin/bin/chef-client -index 45a6af546a..95402c9481 100755 ---- a/chef-bin/bin/chef-client -+++ b/chef-bin/bin/chef-client -@@ -22,4 +22,4 @@ $:.unshift(File.join(File.dirname(__FILE__), "..", "lib")) - require "chef" - require "chef/application/client" - --Chef::Application::Client.new.run(enforce_license: true) -+Chef::Application::Client.new.run(enforce_license: false) diff --git a/omnibus/config/patches/erlang/epmd-require-explicitly-adding-loopback-address.patch b/omnibus/config/patches/erlang/epmd-require-explicitly-adding-loopback-address.patch deleted file mode 100644 index bb4bbd1b1..000000000 --- a/omnibus/config/patches/erlang/epmd-require-explicitly-adding-loopback-address.patch +++ /dev/null @@ -1,83 +0,0 @@ -From fae952def3698b588b96231862123ee3547c702e Mon Sep 17 00:00:00 2001 -From: Steven Danna -Date: Tue, 14 Nov 2017 21:08:05 +0000 -Subject: [PATCH] epmd: require explicitly adding address - -Based on the following PR: - - https://github.com/erlang/otp/pull/1075/commits/0800214dc6aec5327f4e984047dd05a8829ae5e4 ---- - erts/epmd/src/epmd_srv.c | 31 ++++++++++++------------------- - 1 file changed, 12 insertions(+), 19 deletions(-) - -diff --git a/erts/epmd/src/epmd_srv.c b/erts/epmd/src/epmd_srv.c -index e1bac99ef9..f42a97330e 100644 ---- a/erts/epmd/src/epmd_srv.c -+++ b/erts/epmd/src/epmd_srv.c -@@ -257,14 +257,6 @@ void run(EpmdVars *g) - char *tmp = NULL; - char *token = NULL; - -- /* Always listen on the loopback. */ -- SET_ADDR(iserv_addr[num_sockets],htonl(INADDR_LOOPBACK),sport); -- num_sockets++; --#if defined(EPMD6) -- SET_ADDR6(iserv_addr[num_sockets],in6addr_loopback,sport); -- num_sockets++; --#endif -- - if ((tmp = strdup(g->addresses)) == NULL) - { - dbg_perror(g,"cannot allocate memory"); -@@ -278,7 +270,6 @@ void run(EpmdVars *g) - struct in_addr addr; - #if defined(EPMD6) - struct in6_addr addr6; -- struct sockaddr_storage *sa = &iserv_addr[num_sockets]; - - if (inet_pton(AF_INET6,token,&addr6) == 1) - { -@@ -301,15 +292,6 @@ void run(EpmdVars *g) - epmd_cleanup_exit(g,1); - } - --#if defined(EPMD6) -- if (sa->ss_family == AF_INET6 && IN6_IS_ADDR_LOOPBACK(&addr6)) -- continue; -- -- if (sa->ss_family == AF_INET) --#endif -- if (IS_ADDR_LOOPBACK(addr)) -- continue; -- - num_sockets++; - - if (num_sockets >= MAX_LISTEN_SOCKETS) -@@ -374,13 +356,24 @@ void run(EpmdVars *g) - switch (errno) { - case EAFNOSUPPORT: - case EPROTONOSUPPORT: -+ /* -+ * Log error but continue. We can get here for -+ * in6addr_any on machines that don't have IPv6 -+ * support. If we can't bind any addresses, we'll -+ * exit further down -+ * -+ */ -+ dbg_perror(g,"error opening stream socket"); - continue; - default: - dbg_perror(g,"error opening stream socket"); - epmd_cleanup_exit(g,1); - } - } -- g->listenfd[bound++] = listensock[i]; -+ else -+ { -+ g->listenfd[bound++] = listensock[i]; -+ } - - #if HAVE_DECL_IPV6_V6ONLY - opt = 1; --- -2.14.1 diff --git a/omnibus/config/patches/libedit/freebsd-vi-fix.patch b/omnibus/config/patches/libedit/freebsd-vi-fix.patch deleted file mode 100644 index ffb5227f4..000000000 --- a/omnibus/config/patches/libedit/freebsd-vi-fix.patch +++ /dev/null @@ -1,24 +0,0 @@ -diff -ruN libedit-20120601-3.0/src/vi.c libedit-20120601-3.0.fixed/src/vi.c ---- libedit-20120601-3.0/src/vi.c 2012-03-11 09:54:58.000000000 +0000 -+++ libedit-20120601-3.0.fixed/src/vi.c 2013-02-08 05:22:16.338954507 +0000 -@@ -918,17 +918,15 @@ - * NB: posix implies that we should enter insert mode, however - * this is against historical precedent... - */ --#ifdef __weak_reference --__weakref_visible char *my_get_alias_text(const char *) -- __weak_reference(get_alias_text); --#endif - protected el_action_t - /*ARGSUSED*/ - vi_alias(EditLine *el, Int c __attribute__((__unused__))) - { --#ifdef __weak_reference -+#ifdef __weak_extern - char alias_name[3]; - char *alias_text; -+ extern __weakref_visible char *my_get_alias_text(const char *); -+ __weak_extern(get_alias_text); - - if (my_get_alias_text == 0) { - return CC_ERROR; diff --git a/omnibus/config/patches/libedit/openbsd-weak-alias-fix.patch b/omnibus/config/patches/libedit/openbsd-weak-alias-fix.patch deleted file mode 100644 index 73d99af12..000000000 --- a/omnibus/config/patches/libedit/openbsd-weak-alias-fix.patch +++ /dev/null @@ -1,48 +0,0 @@ -diff -ur libedit-20120601-3.0.orig/src/strlcat.c libedit-20120601-3.0/src/strlcat.c ---- libedit-20120601-3.0.orig/src/strlcat.c Wed May 13 17:47:58 2015 -+++ libedit-20120601-3.0/src/strlcat.c Wed May 13 17:48:14 2015 -@@ -29,7 +29,7 @@ - - #ifdef _LIBC - # ifdef __weak_alias --__weak_alias(strlcat, _strlcat) -+//__weak_alias(strlcat, _strlcat) - # endif - #endif - -diff -ur libedit-20120601-3.0.orig/src/strlcpy.c libedit-20120601-3.0/src/strlcpy.c ---- libedit-20120601-3.0.orig/src/strlcpy.c Wed May 13 17:47:58 2015 -+++ libedit-20120601-3.0/src/strlcpy.c Wed May 13 17:48:14 2015 -@@ -29,7 +29,7 @@ - - #ifdef _LIBC - # ifdef __weak_alias --__weak_alias(strlcpy, _strlcpy) -+//__weak_alias(strlcpy, _strlcpy) - # endif - #endif - -diff -ur libedit-20120601-3.0.orig/src/unvis.c libedit-20120601-3.0/src/unvis.c ---- libedit-20120601-3.0.orig/src/unvis.c Wed May 13 17:47:58 2015 -+++ libedit-20120601-3.0/src/unvis.c Wed May 13 17:48:14 2015 -@@ -50,7 +50,7 @@ - #include - - #ifdef __weak_alias --__weak_alias(strnunvisx,_strnunvisx) -+//__weak_alias(strnunvisx,_strnunvisx) - #endif - - #if !HAVE_VIS -diff -ur libedit-20120601-3.0.orig/src/vis.c libedit-20120601-3.0/src/vis.c ---- libedit-20120601-3.0.orig/src/vis.c Wed May 13 17:47:58 2015 -+++ libedit-20120601-3.0/src/vis.c Wed May 13 17:48:14 2015 -@@ -69,7 +69,7 @@ - #include - - #ifdef __weak_alias --__weak_alias(strvisx,_strvisx) -+//__weak_alias(strvisx,_strvisx) - #endif - - #if !HAVE_VIS || !HAVE_SVIS diff --git a/omnibus/config/patches/libffi/libffi-3.2.1-disable-multi-os-directory.patch b/omnibus/config/patches/libffi/libffi-3.2.1-disable-multi-os-directory.patch deleted file mode 100644 index 8296e2095..000000000 --- a/omnibus/config/patches/libffi/libffi-3.2.1-disable-multi-os-directory.patch +++ /dev/null @@ -1,83 +0,0 @@ ---- libffi-3.2.1-orig/configure.ac 2014-11-12 05:56:51.000000000 -0600 -+++ libffi-3.2.1/configure.ac 2015-10-29 15:53:41.695055040 -0500 -@@ -590,6 +590,10 @@ - AC_DEFINE(USING_PURIFY, 1, [Define this if you are using Purify and want to suppress spurious messages.]) - fi) - -+AC_ARG_ENABLE(multi-os-directory, -+[ --disable-multi-os-directory -+ disable use of gcc --print-multi-os-directory to change the library installation directory]) -+ - # These variables are only ever used when we cross-build to X86_WIN32. - # And we only support this with GCC, so... - if test "x$GCC" = "xyes"; then -@@ -601,11 +605,13 @@ - toolexecdir="${libdir}"/gcc-lib/'$(target_alias)' - toolexeclibdir="${libdir}" - fi -- multi_os_directory=`$CC $CFLAGS -print-multi-os-directory` -- case $multi_os_directory in -- .) ;; # Avoid trailing /. -- ../*) toolexeclibdir=$toolexeclibdir/$multi_os_directory ;; -- esac -+ if test x"$enable_multi_os_directory" != x"no"; then -+ multi_os_directory=`$CC $CFLAGS -print-multi-os-directory` -+ case $multi_os_directory in -+ .) ;; # Avoid trailing /. -+ ../*) toolexeclibdir=$toolexeclibdir/$multi_os_directory ;; -+ esac -+ fi - AC_SUBST(toolexecdir) - else - toolexeclibdir="${libdir}" ---- libffi-3.2.1-orig/configure 2014-11-12 11:59:57.000000000 +0000 -+++ libffi-3.2.1/configure 2015-10-30 19:50:51.082221000 +0000 -@@ -886,6 +886,7 @@ - enable_structs - enable_raw_api - enable_purify_safety -+enable_multi_os_directory - ' - ac_precious_vars='build_alias - host_alias -@@ -1538,6 +1539,8 @@ - --disable-structs omit code for struct support - --disable-raw-api make the raw api unavailable - --enable-purify-safety purify-safe mode -+ --disable-multi-os-directory -+ disable use of gcc --print-multi-os-directory to change the library installation directory - - Optional Packages: - --with-PACKAGE[=ARG] use PACKAGE [ARG=yes] -@@ -18714,6 +18717,12 @@ - fi - - -+# Check whether --enable-multi-os-directory was given. -+if test "${enable_multi_os_directory+set}" = set; then : -+ enableval=$enable_multi_os_directory; -+fi -+ -+ - # These variables are only ever used when we cross-build to X86_WIN32. - # And we only support this with GCC, so... - if test "x$GCC" = "xyes"; then -@@ -18725,11 +18734,13 @@ - toolexecdir="${libdir}"/gcc-lib/'$(target_alias)' - toolexeclibdir="${libdir}" - fi -- multi_os_directory=`$CC $CFLAGS -print-multi-os-directory` -- case $multi_os_directory in -- .) ;; # Avoid trailing /. -- ../*) toolexeclibdir=$toolexeclibdir/$multi_os_directory ;; -- esac -+ if test x"$enable_multi_os_directory" != x"no"; then -+ multi_os_directory=`$CC $CFLAGS -print-multi-os-directory` -+ case $multi_os_directory in -+ .) ;; # Avoid trailing /. -+ ../*) toolexeclibdir=$toolexeclibdir/$multi_os_directory ;; -+ esac -+ fi - - else - toolexeclibdir="${libdir}" diff --git a/omnibus/config/patches/libffi/libffi-3.3-arm64.patch b/omnibus/config/patches/libffi/libffi-3.3-arm64.patch deleted file mode 100644 index 2702f78d5..000000000 --- a/omnibus/config/patches/libffi/libffi-3.3-arm64.patch +++ /dev/null @@ -1,9608 +0,0 @@ -diff -ur libffi-3.3/Makefile.in libffi-3.3.new/Makefile.in ---- libffi-3.3/Makefile.in 2019-11-23 06:59:04.000000000 -0700 -+++ libffi-3.3.new/Makefile.in 2021-01-04 19:48:49.000000000 -0700 -@@ -1,7 +1,7 @@ --# Makefile.in generated by automake 1.16.1 from Makefile.am. -+# Makefile.in generated by automake 1.16.3 from Makefile.am. - # @configure_input@ - --# Copyright (C) 1994-2018 Free Software Foundation, Inc. -+# Copyright (C) 1994-2020 Free Software Foundation, Inc. - - # This Makefile.in is free software; the Free Software Foundation - # gives unlimited permission to copy and/or distribute it, -@@ -303,8 +303,8 @@ - $(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)fficonfig.h.in -+am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) \ -+ fficonfig.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. -@@ -326,8 +326,8 @@ - CSCOPE = cscope - DIST_SUBDIRS = include testsuite man doc - am__DIST_COMMON = $(srcdir)/Makefile.in $(srcdir)/fficonfig.h.in \ -- $(srcdir)/libffi.pc.in compile config.guess config.sub depcomp \ -- install-sh ltmain.sh missing -+ $(srcdir)/libffi.pc.in ChangeLog compile config.guess \ -+ config.sub depcomp install-sh ltmain.sh missing - DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) - distdir = $(PACKAGE)-$(VERSION) - top_distdir = $(distdir) -@@ -366,6 +366,8 @@ - DIST_ARCHIVES = $(distdir).tar.gz - GZIP_ENV = --best - DIST_TARGETS = 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$$' -@@ -1529,6 +1531,10 @@ - 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 -@@ -1571,6 +1577,8 @@ - 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) -@@ -1586,7 +1594,7 @@ - $(DISTCHECK_CONFIGURE_FLAGS) \ - --srcdir=../.. --prefix="$$dc_install_base" \ - && $(MAKE) $(AM_MAKEFLAGS) \ -- && $(MAKE) $(AM_MAKEFLAGS) dvi \ -+ && $(MAKE) $(AM_MAKEFLAGS) $(AM_DISTCHECK_DVI_TARGET) \ - && $(MAKE) $(AM_MAKEFLAGS) check \ - && $(MAKE) $(AM_MAKEFLAGS) install \ - && $(MAKE) $(AM_MAKEFLAGS) installcheck \ -@@ -1987,20 +1995,21 @@ - clean-generic clean-libtool clean-noinstLTLIBRARIES \ - clean-toolexeclibLTLIBRARIES cscope cscopelist-am ctags \ - ctags-am dist dist-all dist-bzip2 dist-gzip dist-hook \ -- dist-lzip dist-shar dist-tarZ dist-xz dist-zip distcheck \ -- distclean distclean-compile 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 install-toolexeclibLTLIBRARIES \ -- 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-pkgconfigDATA uninstall-toolexeclibLTLIBRARIES -+ dist-lzip dist-shar dist-tarZ dist-xz dist-zip dist-zstd \ -+ distcheck distclean distclean-compile 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 \ -+ install-toolexeclibLTLIBRARIES 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-pkgconfigDATA \ -+ uninstall-toolexeclibLTLIBRARIES - - .PRECIOUS: Makefile - -diff -ur libffi-3.3/aclocal.m4 libffi-3.3.new/aclocal.m4 ---- libffi-3.3/aclocal.m4 2019-11-23 06:58:58.000000000 -0700 -+++ libffi-3.3.new/aclocal.m4 2021-01-04 19:48:48.000000000 -0700 -@@ -1,6 +1,6 @@ --# generated automatically by aclocal 1.16.1 -*- Autoconf -*- -+# generated automatically by aclocal 1.16.3 -*- Autoconf -*- - --# Copyright (C) 1996-2018 Free Software Foundation, Inc. -+# Copyright (C) 1996-2020 Free Software Foundation, Inc. - - # This file is free software; the Free Software Foundation - # gives unlimited permission to copy and/or distribute it, -@@ -930,7 +930,7 @@ - dnl aclocal-1.4 backwards compatibility: - dnl AC_DEFUN([AC_LTDL_DLSYM_USCORE], []) - --# Copyright (C) 2002-2018 Free Software Foundation, Inc. -+# Copyright (C) 2002-2020 Free Software Foundation, Inc. - # - # This file is free software; the Free Software Foundation - # gives unlimited permission to copy and/or distribute it, -@@ -945,7 +945,7 @@ - [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.1], [], -+m4_if([$1], [1.16.3], [], - [AC_FATAL([Do not call $0, use AM_INIT_AUTOMAKE([$1]).])])dnl - ]) - -@@ -961,14 +961,14 @@ - # 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.1])dnl -+[AM_AUTOMAKE_VERSION([1.16.3])dnl - m4_ifndef([AC_AUTOCONF_VERSION], - [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl - _AM_AUTOCONF_VERSION(m4_defn([AC_AUTOCONF_VERSION]))]) - - # Figure out how to run the assembler. -*- Autoconf -*- - --# Copyright (C) 2001-2018 Free Software Foundation, Inc. -+# Copyright (C) 2001-2020 Free Software Foundation, Inc. - # - # This file is free software; the Free Software Foundation - # gives unlimited permission to copy and/or distribute it, -@@ -988,7 +988,7 @@ - - # AM_AUX_DIR_EXPAND -*- Autoconf -*- - --# Copyright (C) 2001-2018 Free Software Foundation, Inc. -+# Copyright (C) 2001-2020 Free Software Foundation, Inc. - # - # This file is free software; the Free Software Foundation - # gives unlimited permission to copy and/or distribute it, -@@ -1040,7 +1040,7 @@ - - # AM_CONDITIONAL -*- Autoconf -*- - --# Copyright (C) 1997-2018 Free Software Foundation, Inc. -+# Copyright (C) 1997-2020 Free Software Foundation, Inc. - # - # This file is free software; the Free Software Foundation - # gives unlimited permission to copy and/or distribute it, -@@ -1071,7 +1071,7 @@ - Usually this means the macro was only invoked conditionally.]]) - fi])]) - --# Copyright (C) 1999-2018 Free Software Foundation, Inc. -+# Copyright (C) 1999-2020 Free Software Foundation, Inc. - # - # This file is free software; the Free Software Foundation - # gives unlimited permission to copy and/or distribute it, -@@ -1262,7 +1262,7 @@ - - # Generate code to set up dependency tracking. -*- Autoconf -*- - --# Copyright (C) 1999-2018 Free Software Foundation, Inc. -+# Copyright (C) 1999-2020 Free Software Foundation, Inc. - # - # This file is free software; the Free Software Foundation - # gives unlimited permission to copy and/or distribute it, -@@ -1301,7 +1301,9 @@ - done - if test $am_rc -ne 0; then - AC_MSG_FAILURE([Something went wrong bootstrapping makefile fragments -- for automatic dependency tracking. Try re-running configure with the -+ 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 -@@ -1328,7 +1330,7 @@ - - # Do all the work for Automake. -*- Autoconf -*- - --# Copyright (C) 1996-2018 Free Software Foundation, Inc. -+# Copyright (C) 1996-2020 Free Software Foundation, Inc. - # - # This file is free software; the Free Software Foundation - # gives unlimited permission to copy and/or distribute it, -@@ -1525,7 +1527,7 @@ - done - echo "timestamp for $_am_arg" >`AS_DIRNAME(["$_am_arg"])`/stamp-h[]$_am_stamp_count]) - --# Copyright (C) 2001-2018 Free Software Foundation, Inc. -+# Copyright (C) 2001-2020 Free Software Foundation, Inc. - # - # This file is free software; the Free Software Foundation - # gives unlimited permission to copy and/or distribute it, -@@ -1546,7 +1548,7 @@ - fi - AC_SUBST([install_sh])]) - --# Copyright (C) 2003-2018 Free Software Foundation, Inc. -+# Copyright (C) 2003-2020 Free Software Foundation, Inc. - # - # This file is free software; the Free Software Foundation - # gives unlimited permission to copy and/or distribute it, -@@ -1568,7 +1570,7 @@ - # Add --enable-maintainer-mode option to configure. -*- Autoconf -*- - # From Jim Meyering - --# Copyright (C) 1996-2018 Free Software Foundation, Inc. -+# Copyright (C) 1996-2020 Free Software Foundation, Inc. - # - # This file is free software; the Free Software Foundation - # gives unlimited permission to copy and/or distribute it, -@@ -1603,7 +1605,7 @@ - - # Check to see how 'make' treats includes. -*- Autoconf -*- - --# Copyright (C) 2001-2018 Free Software Foundation, Inc. -+# Copyright (C) 2001-2020 Free Software Foundation, Inc. - # - # This file is free software; the Free Software Foundation - # gives unlimited permission to copy and/or distribute it, -@@ -1646,7 +1648,7 @@ - - # Fake the existence of programs that GNU maintainers use. -*- Autoconf -*- - --# Copyright (C) 1997-2018 Free Software Foundation, Inc. -+# Copyright (C) 1997-2020 Free Software Foundation, Inc. - # - # This file is free software; the Free Software Foundation - # gives unlimited permission to copy and/or distribute it, -@@ -1667,12 +1669,7 @@ - [AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl - AC_REQUIRE_AUX_FILE([missing])dnl - if test x"${MISSING+set}" != xset; then -- case $am_aux_dir in -- *\ * | *\ *) -- MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;; -- *) -- MISSING="\${SHELL} $am_aux_dir/missing" ;; -- esac -+ MISSING="\${SHELL} '$am_aux_dir/missing'" - fi - # Use eval to expand $SHELL - if eval "$MISSING --is-lightweight"; then -@@ -1685,7 +1682,7 @@ - - # Helper functions for option handling. -*- Autoconf -*- - --# Copyright (C) 2001-2018 Free Software Foundation, Inc. -+# Copyright (C) 2001-2020 Free Software Foundation, Inc. - # - # This file is free software; the Free Software Foundation - # gives unlimited permission to copy and/or distribute it, -@@ -1714,7 +1711,7 @@ - AC_DEFUN([_AM_IF_OPTION], - [m4_ifset(_AM_MANGLE_OPTION([$1]), [$2], [$3])]) - --# Copyright (C) 1999-2018 Free Software Foundation, Inc. -+# Copyright (C) 1999-2020 Free Software Foundation, Inc. - # - # This file is free software; the Free Software Foundation - # gives unlimited permission to copy and/or distribute it, -@@ -1761,7 +1758,7 @@ - # For backward compatibility. - AC_DEFUN_ONCE([AM_PROG_CC_C_O], [AC_REQUIRE([AC_PROG_CC])]) - --# Copyright (C) 2001-2018 Free Software Foundation, Inc. -+# Copyright (C) 2001-2020 Free Software Foundation, Inc. - # - # This file is free software; the Free Software Foundation - # gives unlimited permission to copy and/or distribute it, -@@ -1780,7 +1777,7 @@ - - # Check to make sure that the build environment is sane. -*- Autoconf -*- - --# Copyright (C) 1996-2018 Free Software Foundation, Inc. -+# Copyright (C) 1996-2020 Free Software Foundation, Inc. - # - # This file is free software; the Free Software Foundation - # gives unlimited permission to copy and/or distribute it, -@@ -1861,7 +1858,7 @@ - rm -f conftest.file - ]) - --# Copyright (C) 2009-2018 Free Software Foundation, Inc. -+# Copyright (C) 2009-2020 Free Software Foundation, Inc. - # - # This file is free software; the Free Software Foundation - # gives unlimited permission to copy and/or distribute it, -@@ -1921,7 +1918,7 @@ - _AM_SUBST_NOTMAKE([AM_BACKSLASH])dnl - ]) - --# Copyright (C) 2001-2018 Free Software Foundation, Inc. -+# Copyright (C) 2001-2020 Free Software Foundation, Inc. - # - # This file is free software; the Free Software Foundation - # gives unlimited permission to copy and/or distribute it, -@@ -1949,7 +1946,7 @@ - INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s" - AC_SUBST([INSTALL_STRIP_PROGRAM])]) - --# Copyright (C) 2006-2018 Free Software Foundation, Inc. -+# Copyright (C) 2006-2020 Free Software Foundation, Inc. - # - # This file is free software; the Free Software Foundation - # gives unlimited permission to copy and/or distribute it, -@@ -1968,7 +1965,7 @@ - - # Check how to create a tarball. -*- Autoconf -*- - --# Copyright (C) 2004-2018 Free Software Foundation, Inc. -+# Copyright (C) 2004-2020 Free Software Foundation, Inc. - # - # This file is free software; the Free Software Foundation - # gives unlimited permission to copy and/or distribute it, -Only in libffi-3.3.new: autom4te.cache -diff -ur libffi-3.3/compile libffi-3.3.new/compile ---- libffi-3.3/compile 2019-11-01 03:30:05.000000000 -0600 -+++ libffi-3.3.new/compile 2021-01-04 19:48:49.000000000 -0700 -@@ -3,7 +3,7 @@ - - scriptversion=2018-03-07.03; # UTC - --# Copyright (C) 1999-2018 Free Software Foundation, Inc. -+# Copyright (C) 1999-2020 Free Software Foundation, Inc. - # Written by Tom Tromey . - # - # This program is free software; you can redistribute it and/or modify -@@ -53,7 +53,7 @@ - MINGW*) - file_conv=mingw - ;; -- CYGWIN*) -+ CYGWIN* | MSYS*) - file_conv=cygwin - ;; - *) -@@ -67,7 +67,7 @@ - mingw/*) - file=`cmd //C echo "$file " | sed -e 's/"\(.*\) " *$/\1/'` - ;; -- cygwin/*) -+ cygwin/* | msys/*) - file=`cygpath -m "$file" || echo "$file"` - ;; - wine/*) -diff -ur libffi-3.3/config.guess libffi-3.3.new/config.guess ---- libffi-3.3/config.guess 2019-10-31 08:49:54.000000000 -0600 -+++ libffi-3.3.new/config.guess 2021-01-04 19:48:49.000000000 -0700 -@@ -1,8 +1,8 @@ - #! /bin/sh - # Attempt to guess a canonical system name. --# Copyright 1992-2017 Free Software Foundation, Inc. -+# Copyright 1992-2020 Free Software Foundation, Inc. - --timestamp='2017-05-11' -+timestamp='2020-08-17' - - # 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 -@@ -15,7 +15,7 @@ - # 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 . -+# 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 -@@ -27,7 +27,7 @@ - # Originally written by Per Bothner; maintained since 2000 by Ben Elliston. - # - # You can get the latest version of this script from: --# http://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.guess -+# https://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.guess - # - # Please send patches to . - -@@ -39,7 +39,7 @@ - - Output the configuration name of the system \`$me' is run on. - --Operation modes: -+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 -@@ -50,7 +50,7 @@ - GNU config.guess ($timestamp) - - Originally written by Per Bothner. --Copyright 1992-2017 Free Software Foundation, Inc. -+Copyright 1992-2020 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." -@@ -84,8 +84,6 @@ - exit 1 - fi - --trap 'exit 1' 1 2 15 -- - # 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 -@@ -96,34 +94,40 @@ - - # Portable tmp directory creation inspired by the Autoconf team. - --set_cc_for_build=' --trap "exitcode=\$?; (rm -f \$tmpfiles 2>/dev/null; rmdir \$tmp 2>/dev/null) && exit \$exitcode" 0 ; --trap "rm -f \$tmpfiles 2>/dev/null; rmdir \$tmp 2>/dev/null; exit 1" 1 2 13 15 ; --: ${TMPDIR=/tmp} ; -- { 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) ; } || -- { tmp=$TMPDIR/cg-$$ && (umask 077 && mkdir $tmp) && echo "Warning: creating insecure temp directory" >&2 ; } || -- { echo "$me: cannot create a temporary directory in $TMPDIR" >&2 ; exit 1 ; } ; --dummy=$tmp/dummy ; --tmpfiles="$dummy.c $dummy.o $dummy.rel $dummy" ; --case $CC_FOR_BUILD,$HOST_CC,$CC in -- ,,) echo "int x;" > $dummy.c ; -- for c in cc gcc c89 c99 ; do -- if ($c -c -o $dummy.o $dummy.c) >/dev/null 2>&1 ; then -- CC_FOR_BUILD="$c"; 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 ; set_cc_for_build= ;' -+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 -+ { 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) >/dev/null 2>&1 ; then -+if test -f /.attbin/uname ; then - PATH=$PATH:/.attbin ; export PATH - fi - -@@ -132,14 +136,14 @@ - UNAME_SYSTEM=`(uname -s) 2>/dev/null` || UNAME_SYSTEM=unknown - UNAME_VERSION=`(uname -v) 2>/dev/null` || UNAME_VERSION=unknown - --case "${UNAME_SYSTEM}" in -+case "$UNAME_SYSTEM" in - Linux|GNU|GNU/*) - # If the system lacks a compiler, then just pick glibc. - # We could probably try harder. - LIBC=gnu - -- eval $set_cc_for_build -- cat <<-EOF > $dummy.c -+ set_cc_for_build -+ cat <<-EOF > "$dummy.c" - #include - #if defined(__UCLIBC__) - LIBC=uclibc -@@ -149,13 +153,20 @@ - LIBC=gnu - #endif - EOF -- eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep '^LIBC' | sed 's, ,,g'` -+ eval "`$CC_FOR_BUILD -E "$dummy.c" 2>/dev/null | grep '^LIBC' | sed 's, ,,g'`" -+ -+ # If ldd exists, use it to detect musl libc. -+ if command -v ldd >/dev/null && \ -+ ldd --version 2>&1 | grep -q ^musl -+ then -+ LIBC=musl -+ fi - ;; - esac - - # Note: order is significant - the case branches are not exclusive. - --case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in -+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*, -@@ -169,30 +180,30 @@ - # portion of the name. We always set it to "unknown". - sysctl="sysctl -n hw.machine_arch" - UNAME_MACHINE_ARCH=`(uname -p 2>/dev/null || \ -- /sbin/$sysctl 2>/dev/null || \ -- /usr/sbin/$sysctl 2>/dev/null || \ -+ "/sbin/$sysctl" 2>/dev/null || \ -+ "/usr/sbin/$sysctl" 2>/dev/null || \ - echo unknown)` -- case "${UNAME_MACHINE_ARCH}" in -+ case "$UNAME_MACHINE_ARCH" in - 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 -+ 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 ;; -+ *) 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 -+ case "$UNAME_MACHINE_ARCH" in - earm*) - os=netbsdelf - ;; - arm*|i386|m68k|ns32k|sh3*|sparc|vax) -- eval $set_cc_for_build -+ set_cc_for_build - if echo __ELF__ | $CC_FOR_BUILD -E - 2>/dev/null \ - | grep -q __ELF__ - then -@@ -208,10 +219,10 @@ - ;; - esac - # Determine ABI tags. -- case "${UNAME_MACHINE_ARCH}" in -+ case "$UNAME_MACHINE_ARCH" in - earm*) - expr='s/^earmv[0-9]/-eabi/;s/eb$//' -- abi=`echo ${UNAME_MACHINE_ARCH} | sed -e "$expr"` -+ abi=`echo "$UNAME_MACHINE_ARCH" | sed -e "$expr"` - ;; - esac - # The OS release -@@ -219,45 +230,60 @@ - # 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 -+ case "$UNAME_VERSION" in - Debian*) - release='-gnu' - ;; - *) -- release=`echo ${UNAME_RELEASE} | sed -e 's/[-_].*//' | cut -d. -f1,2` -+ 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. -- echo "${machine}-${os}${release}${abi}" -+ echo "$machine-${os}${release}${abi-}" - exit ;; - *:Bitrig:*:*) - UNAME_MACHINE_ARCH=`arch | sed 's/Bitrig.//'` -- echo ${UNAME_MACHINE_ARCH}-unknown-bitrig${UNAME_RELEASE} -+ echo "$UNAME_MACHINE_ARCH"-unknown-bitrig"$UNAME_RELEASE" - exit ;; - *:OpenBSD:*:*) - UNAME_MACHINE_ARCH=`arch | sed 's/OpenBSD.//'` -- echo ${UNAME_MACHINE_ARCH}-unknown-openbsd${UNAME_RELEASE} -+ echo "$UNAME_MACHINE_ARCH"-unknown-openbsd"$UNAME_RELEASE" - exit ;; - *:LibertyBSD:*:*) - UNAME_MACHINE_ARCH=`arch | sed 's/^.*BSD\.//'` -- echo ${UNAME_MACHINE_ARCH}-unknown-libertybsd${UNAME_RELEASE} -+ echo "$UNAME_MACHINE_ARCH"-unknown-libertybsd"$UNAME_RELEASE" -+ exit ;; -+ *:MidnightBSD:*:*) -+ echo "$UNAME_MACHINE"-unknown-midnightbsd"$UNAME_RELEASE" - exit ;; - *:ekkoBSD:*:*) -- echo ${UNAME_MACHINE}-unknown-ekkobsd${UNAME_RELEASE} -+ echo "$UNAME_MACHINE"-unknown-ekkobsd"$UNAME_RELEASE" - exit ;; - *:SolidBSD:*:*) -- echo ${UNAME_MACHINE}-unknown-solidbsd${UNAME_RELEASE} -+ echo "$UNAME_MACHINE"-unknown-solidbsd"$UNAME_RELEASE" -+ exit ;; -+ *:OS108:*:*) -+ echo "$UNAME_MACHINE"-unknown-os108_"$UNAME_RELEASE" - exit ;; - macppc:MirBSD:*:*) -- echo powerpc-unknown-mirbsd${UNAME_RELEASE} -+ echo powerpc-unknown-mirbsd"$UNAME_RELEASE" - exit ;; - *:MirBSD:*:*) -- echo ${UNAME_MACHINE}-unknown-mirbsd${UNAME_RELEASE} -+ echo "$UNAME_MACHINE"-unknown-mirbsd"$UNAME_RELEASE" - exit ;; - *:Sortix:*:*) -- echo ${UNAME_MACHINE}-unknown-sortix -+ echo "$UNAME_MACHINE"-unknown-sortix -+ exit ;; -+ *:Twizzler:*:*) -+ echo "$UNAME_MACHINE"-unknown-twizzler -+ exit ;; -+ *:Redox:*:*) -+ echo "$UNAME_MACHINE"-unknown-redox -+ exit ;; -+ mips:OSF1:*.*) -+ echo mips-dec-osf1 - exit ;; - alpha:OSF1:*:*) - case $UNAME_RELEASE in -@@ -310,28 +336,19 @@ - # 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. -- echo ${UNAME_MACHINE}-dec-osf`echo ${UNAME_RELEASE} | sed -e 's/^[PVTX]//' | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz` -+ echo "$UNAME_MACHINE"-dec-osf"`echo "$UNAME_RELEASE" | sed -e 's/^[PVTX]//' | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz`" - # Reset EXIT trap before exiting to avoid spurious non-zero exit code. - exitcode=$? - trap '' 0 - exit $exitcode ;; -- Alpha\ *:Windows_NT*:*) -- # How do we know it's Interix rather than the generic POSIX subsystem? -- # Should we change UNAME_MACHINE based on the output of uname instead -- # of the specific Alpha model? -- echo alpha-pc-interix -- exit ;; -- 21064:Windows_NT:50:3) -- echo alpha-dec-winnt3.5 -- exit ;; - Amiga*:UNIX_System_V:4.0:*) - echo m68k-unknown-sysv4 - exit ;; - *:[Aa]miga[Oo][Ss]:*:*) -- echo ${UNAME_MACHINE}-unknown-amigaos -+ echo "$UNAME_MACHINE"-unknown-amigaos - exit ;; - *:[Mm]orph[Oo][Ss]:*:*) -- echo ${UNAME_MACHINE}-unknown-morphos -+ echo "$UNAME_MACHINE"-unknown-morphos - exit ;; - *:OS/390:*:*) - echo i370-ibm-openedition -@@ -343,7 +360,7 @@ - echo powerpc-ibm-os400 - exit ;; - arm:RISC*:1.[012]*:*|arm:riscix:1.[012]*:*) -- echo arm-acorn-riscix${UNAME_RELEASE} -+ echo arm-acorn-riscix"$UNAME_RELEASE" - exit ;; - arm*:riscos:*:*|arm*:RISCOS:*:*) - echo arm-unknown-riscos -@@ -370,24 +387,24 @@ - sparc) echo sparc-icl-nx7; exit ;; - esac ;; - s390x:SunOS:*:*) -- echo ${UNAME_MACHINE}-ibm-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` -+ echo "$UNAME_MACHINE"-ibm-solaris2"`echo "$UNAME_RELEASE" | sed -e 's/[^.]*//'`" - exit ;; - sun4H:SunOS:5.*:*) -- echo sparc-hal-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` -+ echo sparc-hal-solaris2"`echo "$UNAME_RELEASE"|sed -e 's/[^.]*//'`" - exit ;; - sun4*:SunOS:5.*:* | tadpole*:SunOS:5.*:*) -- echo sparc-sun-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` -+ echo sparc-sun-solaris2"`echo "$UNAME_RELEASE" | sed -e 's/[^.]*//'`" - exit ;; - i86pc:AuroraUX:5.*:* | i86xen:AuroraUX:5.*:*) -- echo i386-pc-auroraux${UNAME_RELEASE} -+ echo i386-pc-auroraux"$UNAME_RELEASE" - exit ;; - i86pc:SunOS:5.*:* | i86xen:SunOS:5.*:*) -- eval $set_cc_for_build -+ 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 [ "$CC_FOR_BUILD" != no_compiler_found ]; then -+ if test "$CC_FOR_BUILD" != no_compiler_found; then - if (echo '#ifdef __amd64'; echo IS_64BIT_ARCH; echo '#endif') | \ - (CCOPTS="" $CC_FOR_BUILD -E - 2>/dev/null) | \ - grep IS_64BIT_ARCH >/dev/null -@@ -395,13 +412,13 @@ - SUN_ARCH=x86_64 - fi - fi -- echo ${SUN_ARCH}-pc-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` -+ echo "$SUN_ARCH"-pc-solaris2"`echo "$UNAME_RELEASE"|sed -e 's/[^.]*//'`" - exit ;; - 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. -- echo sparc-sun-solaris3`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` -+ echo sparc-sun-solaris3"`echo "$UNAME_RELEASE"|sed -e 's/[^.]*//'`" - exit ;; - sun4*:SunOS:*:*) - case "`/usr/bin/arch -k`" in -@@ -410,25 +427,25 @@ - ;; - esac - # Japanese Language versions have a version number like `4.1.3-JL'. -- echo sparc-sun-sunos`echo ${UNAME_RELEASE}|sed -e 's/-/_/'` -+ echo sparc-sun-sunos"`echo "$UNAME_RELEASE"|sed -e 's/-/_/'`" - exit ;; - sun3*:SunOS:*:*) -- echo m68k-sun-sunos${UNAME_RELEASE} -+ echo m68k-sun-sunos"$UNAME_RELEASE" - exit ;; - 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 -+ test "x$UNAME_RELEASE" = x && UNAME_RELEASE=3 - case "`/bin/arch`" in - sun3) -- echo m68k-sun-sunos${UNAME_RELEASE} -+ echo m68k-sun-sunos"$UNAME_RELEASE" - ;; - sun4) -- echo sparc-sun-sunos${UNAME_RELEASE} -+ echo sparc-sun-sunos"$UNAME_RELEASE" - ;; - esac - exit ;; - aushp:SunOS:*:*) -- echo sparc-auspex-sunos${UNAME_RELEASE} -+ echo sparc-auspex-sunos"$UNAME_RELEASE" - exit ;; - # The situation for MiNT is a little confusing. The machine name - # can be virtually everything (everything which is not -@@ -439,44 +456,44 @@ - # MiNT. But MiNT is downward compatible to TOS, so this should - # be no problem. - atarist[e]:*MiNT:*:* | atarist[e]:*mint:*:* | atarist[e]:*TOS:*:*) -- echo m68k-atari-mint${UNAME_RELEASE} -+ echo m68k-atari-mint"$UNAME_RELEASE" - exit ;; - atari*:*MiNT:*:* | atari*:*mint:*:* | atarist[e]:*TOS:*:*) -- echo m68k-atari-mint${UNAME_RELEASE} -+ echo m68k-atari-mint"$UNAME_RELEASE" - exit ;; - *falcon*:*MiNT:*:* | *falcon*:*mint:*:* | *falcon*:*TOS:*:*) -- echo m68k-atari-mint${UNAME_RELEASE} -+ echo m68k-atari-mint"$UNAME_RELEASE" - exit ;; - milan*:*MiNT:*:* | milan*:*mint:*:* | *milan*:*TOS:*:*) -- echo m68k-milan-mint${UNAME_RELEASE} -+ echo m68k-milan-mint"$UNAME_RELEASE" - exit ;; - hades*:*MiNT:*:* | hades*:*mint:*:* | *hades*:*TOS:*:*) -- echo m68k-hades-mint${UNAME_RELEASE} -+ echo m68k-hades-mint"$UNAME_RELEASE" - exit ;; - *:*MiNT:*:* | *:*mint:*:* | *:*TOS:*:*) -- echo m68k-unknown-mint${UNAME_RELEASE} -+ echo m68k-unknown-mint"$UNAME_RELEASE" - exit ;; - m68k:machten:*:*) -- echo m68k-apple-machten${UNAME_RELEASE} -+ echo m68k-apple-machten"$UNAME_RELEASE" - exit ;; - powerpc:machten:*:*) -- echo powerpc-apple-machten${UNAME_RELEASE} -+ echo powerpc-apple-machten"$UNAME_RELEASE" - exit ;; - RISC*:Mach:*:*) - echo mips-dec-mach_bsd4.3 - exit ;; - RISC*:ULTRIX:*:*) -- echo mips-dec-ultrix${UNAME_RELEASE} -+ echo mips-dec-ultrix"$UNAME_RELEASE" - exit ;; - VAX*:ULTRIX*:*:*) -- echo vax-dec-ultrix${UNAME_RELEASE} -+ echo vax-dec-ultrix"$UNAME_RELEASE" - exit ;; - 2020:CLIX:*:* | 2430:CLIX:*:*) -- echo clipper-intergraph-clix${UNAME_RELEASE} -+ echo clipper-intergraph-clix"$UNAME_RELEASE" - exit ;; - mips:*:*:UMIPS | mips:*:*:RISCos) -- eval $set_cc_for_build -- sed 's/^ //' << EOF >$dummy.c -+ set_cc_for_build -+ sed 's/^ //' << EOF > "$dummy.c" - #ifdef __cplusplus - #include /* for printf() prototype */ - int main (int argc, char *argv[]) { -@@ -485,23 +502,23 @@ - #endif - #if defined (host_mips) && defined (MIPSEB) - #if defined (SYSTYPE_SYSV) -- printf ("mips-mips-riscos%ssysv\n", argv[1]); exit (0); -+ 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); -+ 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); -+ 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` && -+ $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; } -- echo mips-mips-riscos${UNAME_RELEASE} -+ echo mips-mips-riscos"$UNAME_RELEASE" - exit ;; - Motorola:PowerMAX_OS:*:*) - echo powerpc-motorola-powermax -@@ -527,17 +544,17 @@ - AViiON:dgux:*:*) - # DG/UX returns AViiON for all architectures - UNAME_PROCESSOR=`/usr/bin/uname -p` -- if [ $UNAME_PROCESSOR = mc88100 ] || [ $UNAME_PROCESSOR = mc88110 ] -+ if test "$UNAME_PROCESSOR" = mc88100 || test "$UNAME_PROCESSOR" = mc88110 - then -- if [ ${TARGET_BINARY_INTERFACE}x = m88kdguxelfx ] || \ -- [ ${TARGET_BINARY_INTERFACE}x = x ] -+ if test "$TARGET_BINARY_INTERFACE"x = m88kdguxelfx || \ -+ test "$TARGET_BINARY_INTERFACE"x = x - then -- echo m88k-dg-dgux${UNAME_RELEASE} -+ echo m88k-dg-dgux"$UNAME_RELEASE" - else -- echo m88k-dg-dguxbcs${UNAME_RELEASE} -+ echo m88k-dg-dguxbcs"$UNAME_RELEASE" - fi - else -- echo i586-dg-dgux${UNAME_RELEASE} -+ echo i586-dg-dgux"$UNAME_RELEASE" - fi - exit ;; - M88*:DolphinOS:*:*) # DolphinOS (SVR3) -@@ -554,7 +571,7 @@ - echo m68k-tektronix-bsd - exit ;; - *:IRIX*:*:*) -- echo mips-sgi-irix`echo ${UNAME_RELEASE}|sed -e 's/-/_/g'` -+ echo mips-sgi-irix"`echo "$UNAME_RELEASE"|sed -e 's/-/_/g'`" - exit ;; - ????????:AIX?:[12].1:2) # AIX 2.2.1 or AIX 2.1.1 is RT/PC AIX. - echo romp-ibm-aix # uname -m gives an 8 hex-code CPU id -@@ -563,17 +580,17 @@ - echo i386-ibm-aix - exit ;; - ia64:AIX:*:*) -- if [ -x /usr/bin/oslevel ] ; then -+ if test -x /usr/bin/oslevel ; then - IBM_REV=`/usr/bin/oslevel` - else -- IBM_REV=${UNAME_VERSION}.${UNAME_RELEASE} -+ IBM_REV="$UNAME_VERSION.$UNAME_RELEASE" - fi -- echo ${UNAME_MACHINE}-ibm-aix${IBM_REV} -+ echo "$UNAME_MACHINE"-ibm-aix"$IBM_REV" - exit ;; - *:AIX:2:3) - if grep bos325 /usr/include/stdio.h >/dev/null 2>&1; then -- eval $set_cc_for_build -- sed 's/^ //' << EOF >$dummy.c -+ set_cc_for_build -+ sed 's/^ //' << EOF > "$dummy.c" - #include - - main() -@@ -584,7 +601,7 @@ - exit(0); - } - EOF -- if $CC_FOR_BUILD -o $dummy $dummy.c && SYSTEM_NAME=`$dummy` -+ if $CC_FOR_BUILD -o "$dummy" "$dummy.c" && SYSTEM_NAME=`"$dummy"` - then - echo "$SYSTEM_NAME" - else -@@ -598,27 +615,27 @@ - exit ;; - *: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 -+ if /usr/sbin/lsattr -El "$IBM_CPU_ID" | grep ' POWER' >/dev/null 2>&1; then - IBM_ARCH=rs6000 - else - IBM_ARCH=powerpc - fi -- if [ -x /usr/bin/lslpp ] ; then -+ 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} -+ IBM_REV="$UNAME_VERSION.$UNAME_RELEASE" - fi -- echo ${IBM_ARCH}-ibm-aix${IBM_REV} -+ echo "$IBM_ARCH"-ibm-aix"$IBM_REV" - exit ;; - *:AIX:*:*) - echo rs6000-ibm-aix - exit ;; -- ibmrt:4.4BSD:*|romp-ibm:BSD:*) -+ ibmrt:4.4BSD:*|romp-ibm:4.4BSD:*) - echo romp-ibm-bsd4.4 - exit ;; - ibmrt:*BSD:*|romp-ibm:BSD:*) # covers RT/PC BSD and -- echo romp-ibm-bsd${UNAME_RELEASE} # 4.3 with uname added to -+ echo romp-ibm-bsd"$UNAME_RELEASE" # 4.3 with uname added to - exit ;; # report: romp-ibm BSD 4.3 - *:BOSX:*:*) - echo rs6000-bull-bosx -@@ -633,28 +650,28 @@ - echo m68k-hp-bsd4.4 - exit ;; - 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 ;; -+ 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 [ -x /usr/bin/getconf ]; then -+ 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 -+ 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 -+ 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 [ "${HP_ARCH}" = "" ]; then -- eval $set_cc_for_build -- sed 's/^ //' << EOF >$dummy.c -+ if test "$HP_ARCH" = ""; then -+ set_cc_for_build -+ sed 's/^ //' << EOF > "$dummy.c" - - #define _HPUX_SOURCE - #include -@@ -687,13 +704,13 @@ - exit (0); - } - EOF -- (CCOPTS="" $CC_FOR_BUILD -o $dummy $dummy.c 2>/dev/null) && HP_ARCH=`$dummy` -+ (CCOPTS="" $CC_FOR_BUILD -o "$dummy" "$dummy.c" 2>/dev/null) && HP_ARCH=`"$dummy"` - test -z "$HP_ARCH" && HP_ARCH=hppa - fi ;; - esac -- if [ ${HP_ARCH} = hppa2.0w ] -+ if test "$HP_ARCH" = hppa2.0w - then -- eval $set_cc_for_build -+ 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 -@@ -712,15 +729,15 @@ - HP_ARCH=hppa64 - fi - fi -- echo ${HP_ARCH}-hp-hpux${HPUX_REV} -+ echo "$HP_ARCH"-hp-hpux"$HPUX_REV" - exit ;; - ia64:HP-UX:*:*) -- HPUX_REV=`echo ${UNAME_RELEASE}|sed -e 's/[^.]*.[0B]*//'` -- echo ia64-hp-hpux${HPUX_REV} -+ HPUX_REV=`echo "$UNAME_RELEASE"|sed -e 's/[^.]*.[0B]*//'` -+ echo ia64-hp-hpux"$HPUX_REV" - exit ;; - 3050*:HI-UX:*:*) -- eval $set_cc_for_build -- sed 's/^ //' << EOF >$dummy.c -+ set_cc_for_build -+ sed 's/^ //' << EOF > "$dummy.c" - #include - int - main () -@@ -745,11 +762,11 @@ - exit (0); - } - EOF -- $CC_FOR_BUILD -o $dummy $dummy.c && SYSTEM_NAME=`$dummy` && -+ $CC_FOR_BUILD -o "$dummy" "$dummy.c" && SYSTEM_NAME=`"$dummy"` && - { echo "$SYSTEM_NAME"; exit; } - echo unknown-hitachi-hiuxwe2 - exit ;; -- 9000/7??:4.3bsd:*:* | 9000/8?[79]:4.3bsd:*:* ) -+ 9000/7??:4.3bsd:*:* | 9000/8?[79]:4.3bsd:*:*) - echo hppa1.1-hp-bsd - exit ;; - 9000/8??:4.3bsd:*:*) -@@ -758,17 +775,17 @@ - *9??*:MPE/iX:*:* | *3000*:MPE/iX:*:*) - echo hppa1.0-hp-mpeix - exit ;; -- hp7??:OSF1:*:* | hp8?[79]:OSF1:*:* ) -+ hp7??:OSF1:*:* | hp8?[79]:OSF1:*:*) - echo hppa1.1-hp-osf - exit ;; - hp8??:OSF1:*:*) - echo hppa1.0-hp-osf - exit ;; - i*86:OSF1:*:*) -- if [ -x /usr/sbin/sysversion ] ; then -- echo ${UNAME_MACHINE}-unknown-osf1mk -+ if test -x /usr/sbin/sysversion ; then -+ echo "$UNAME_MACHINE"-unknown-osf1mk - else -- echo ${UNAME_MACHINE}-unknown-osf1 -+ echo "$UNAME_MACHINE"-unknown-osf1 - fi - exit ;; - parisc*:Lites*:*:*) -@@ -793,131 +810,123 @@ - echo c4-convex-bsd - exit ;; - CRAY*Y-MP:*:*:*) -- echo ymp-cray-unicos${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' -+ echo ymp-cray-unicos"$UNAME_RELEASE" | sed -e 's/\.[^.]*$/.X/' - exit ;; - CRAY*[A-Z]90:*:*:*) -- echo ${UNAME_MACHINE}-cray-unicos${UNAME_RELEASE} \ -+ 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:*:*:*) -- echo t90-cray-unicos${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' -+ echo t90-cray-unicos"$UNAME_RELEASE" | sed -e 's/\.[^.]*$/.X/' - exit ;; - CRAY*T3E:*:*:*) -- echo alphaev5-cray-unicosmk${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' -+ echo alphaev5-cray-unicosmk"$UNAME_RELEASE" | sed -e 's/\.[^.]*$/.X/' - exit ;; - CRAY*SV1:*:*:*) -- echo sv1-cray-unicos${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' -+ echo sv1-cray-unicos"$UNAME_RELEASE" | sed -e 's/\.[^.]*$/.X/' - exit ;; - *:UNICOS/mp:*:*) -- echo craynv-cray-unicosmp${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' -+ echo craynv-cray-unicosmp"$UNAME_RELEASE" | sed -e 's/\.[^.]*$/.X/' - exit ;; - 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/ /_/'` -+ FUJITSU_REL=`echo "$UNAME_RELEASE" | sed -e 's/ /_/'` - echo "${FUJITSU_PROC}-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}" - exit ;; - 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/ /_/'` -+ FUJITSU_REL=`echo "$UNAME_RELEASE" | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz | sed -e 's/ /_/'` - echo "sparc-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}" - exit ;; - i*86:BSD/386:*:* | i*86:BSD/OS:*:* | *:Ascend\ Embedded/OS:*:*) -- echo ${UNAME_MACHINE}-pc-bsdi${UNAME_RELEASE} -+ echo "$UNAME_MACHINE"-pc-bsdi"$UNAME_RELEASE" - exit ;; - sparc*:BSD/OS:*:*) -- echo sparc-unknown-bsdi${UNAME_RELEASE} -+ echo sparc-unknown-bsdi"$UNAME_RELEASE" - exit ;; - *:BSD/OS:*:*) -- echo ${UNAME_MACHINE}-unknown-bsdi${UNAME_RELEASE} -+ echo "$UNAME_MACHINE"-unknown-bsdi"$UNAME_RELEASE" -+ exit ;; -+ 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 -+ echo "${UNAME_PROCESSOR}"-unknown-freebsd"`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'`"-gnueabi -+ else -+ echo "${UNAME_PROCESSOR}"-unknown-freebsd"`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'`"-gnueabihf -+ fi - exit ;; - *:FreeBSD:*:*) - UNAME_PROCESSOR=`/usr/bin/uname -p` -- case ${UNAME_PROCESSOR} in -+ case "$UNAME_PROCESSOR" in - amd64) - UNAME_PROCESSOR=x86_64 ;; - i386) - UNAME_PROCESSOR=i586 ;; - esac -- echo ${UNAME_PROCESSOR}-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` -+ echo "$UNAME_PROCESSOR"-unknown-freebsd"`echo "$UNAME_RELEASE"|sed -e 's/[-(].*//'`" - exit ;; - i*:CYGWIN*:*) -- echo ${UNAME_MACHINE}-pc-cygwin -+ echo "$UNAME_MACHINE"-pc-cygwin - exit ;; - *:MINGW64*:*) -- echo ${UNAME_MACHINE}-pc-mingw64 -+ echo "$UNAME_MACHINE"-pc-mingw64 - exit ;; - *:MINGW*:*) -- echo ${UNAME_MACHINE}-pc-mingw32 -+ echo "$UNAME_MACHINE"-pc-mingw32 - exit ;; - *:MSYS*:*) -- echo ${UNAME_MACHINE}-pc-msys -- exit ;; -- i*:windows32*:*) -- # uname -m includes "-pc" on this system. -- echo ${UNAME_MACHINE}-mingw32 -+ echo "$UNAME_MACHINE"-pc-msys - exit ;; - i*:PW*:*) -- echo ${UNAME_MACHINE}-pc-pw32 -+ echo "$UNAME_MACHINE"-pc-pw32 - exit ;; - *:Interix*:*) -- case ${UNAME_MACHINE} in -+ case "$UNAME_MACHINE" in - x86) -- echo i586-pc-interix${UNAME_RELEASE} -+ echo i586-pc-interix"$UNAME_RELEASE" - exit ;; - authenticamd | genuineintel | EM64T) -- echo x86_64-unknown-interix${UNAME_RELEASE} -+ echo x86_64-unknown-interix"$UNAME_RELEASE" - exit ;; - IA64) -- echo ia64-unknown-interix${UNAME_RELEASE} -+ echo ia64-unknown-interix"$UNAME_RELEASE" - exit ;; - esac ;; -- [345]86:Windows_95:* | [345]86:Windows_98:* | [345]86:Windows_NT:*) -- echo i${UNAME_MACHINE}-pc-mks -- exit ;; -- 8664:Windows_NT:*) -- echo x86_64-pc-mks -- exit ;; -- i*:Windows_NT*:* | Pentium*:Windows_NT*:*) -- # How do we know it's Interix rather than the generic POSIX subsystem? -- # It also conflicts with pre-2.0 versions of AT&T UWIN. Should we -- # UNAME_MACHINE based on the output of uname instead of i386? -- echo i586-pc-interix -- exit ;; - i*:UWIN*:*) -- echo ${UNAME_MACHINE}-pc-uwin -+ echo "$UNAME_MACHINE"-pc-uwin - exit ;; - amd64:CYGWIN*:*:* | x86_64:CYGWIN*:*:*) -- echo x86_64-unknown-cygwin -- exit ;; -- p*:CYGWIN*:*) -- echo powerpcle-unknown-cygwin -+ echo x86_64-pc-cygwin - exit ;; - prep*:SunOS:5.*:*) -- echo powerpcle-unknown-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` -+ echo powerpcle-unknown-solaris2"`echo "$UNAME_RELEASE"|sed -e 's/[^.]*//'`" - exit ;; - *:GNU:*:*) - # the GNU system -- echo `echo ${UNAME_MACHINE}|sed -e 's,[-/].*$,,'`-unknown-${LIBC}`echo ${UNAME_RELEASE}|sed -e 's,/.*$,,'` -+ echo "`echo "$UNAME_MACHINE"|sed -e 's,[-/].*$,,'`-unknown-$LIBC`echo "$UNAME_RELEASE"|sed -e 's,/.*$,,'`" - exit ;; - *:GNU/*:*:*) - # other systems with GNU libc and userland -- echo ${UNAME_MACHINE}-unknown-`echo ${UNAME_SYSTEM} | sed 's,^[^/]*/,,' | tr "[:upper:]" "[:lower:]"``echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'`-${LIBC} -+ echo "$UNAME_MACHINE-unknown-`echo "$UNAME_SYSTEM" | sed 's,^[^/]*/,,' | tr "[:upper:]" "[:lower:]"``echo "$UNAME_RELEASE"|sed -e 's/[-(].*//'`-$LIBC" - exit ;; -- i*86:Minix:*:*) -- echo ${UNAME_MACHINE}-pc-minix -+ *:Minix:*:*) -+ echo "$UNAME_MACHINE"-unknown-minix - exit ;; - aarch64:Linux:*:*) -- echo ${UNAME_MACHINE}-unknown-linux-${LIBC} -+ echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" - exit ;; - aarch64_be:Linux:*:*) - UNAME_MACHINE=aarch64_be -- echo ${UNAME_MACHINE}-unknown-linux-${LIBC} -+ echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" - exit ;; - alpha:Linux:*:*) -- case `sed -n '/^cpu model/s/^.*: \(.*\)/\1/p' < /proc/cpuinfo` in -+ 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 ;; -@@ -928,140 +937,178 @@ - esac - objdump --private-headers /bin/sh | grep -q ld.so.1 - if test "$?" = 0 ; then LIBC=gnulibc1 ; fi -- echo ${UNAME_MACHINE}-unknown-linux-${LIBC} -+ echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" - exit ;; - arc:Linux:*:* | arceb:Linux:*:*) -- echo ${UNAME_MACHINE}-unknown-linux-${LIBC} -+ echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" - exit ;; - arm*:Linux:*:*) -- eval $set_cc_for_build -+ set_cc_for_build - if echo __ARM_EABI__ | $CC_FOR_BUILD -E - 2>/dev/null \ - | grep -q __ARM_EABI__ - then -- echo ${UNAME_MACHINE}-unknown-linux-${LIBC} -+ echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" - else - if echo __ARM_PCS_VFP | $CC_FOR_BUILD -E - 2>/dev/null \ - | grep -q __ARM_PCS_VFP - then -- echo ${UNAME_MACHINE}-unknown-linux-${LIBC}eabi -+ echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"eabi - else -- echo ${UNAME_MACHINE}-unknown-linux-${LIBC}eabihf -+ echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"eabihf - fi - fi - exit ;; - avr32*:Linux:*:*) -- echo ${UNAME_MACHINE}-unknown-linux-${LIBC} -+ echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" - exit ;; - cris:Linux:*:*) -- echo ${UNAME_MACHINE}-axis-linux-${LIBC} -+ echo "$UNAME_MACHINE"-axis-linux-"$LIBC" - exit ;; - crisv32:Linux:*:*) -- echo ${UNAME_MACHINE}-axis-linux-${LIBC} -+ echo "$UNAME_MACHINE"-axis-linux-"$LIBC" - exit ;; - e2k:Linux:*:*) -- echo ${UNAME_MACHINE}-unknown-linux-${LIBC} -+ echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" - exit ;; - frv:Linux:*:*) -- echo ${UNAME_MACHINE}-unknown-linux-${LIBC} -+ echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" - exit ;; - hexagon:Linux:*:*) -- echo ${UNAME_MACHINE}-unknown-linux-${LIBC} -+ echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" - exit ;; - i*86:Linux:*:*) -- echo ${UNAME_MACHINE}-pc-linux-${LIBC} -+ echo "$UNAME_MACHINE"-pc-linux-"$LIBC" - exit ;; - ia64:Linux:*:*) -- echo ${UNAME_MACHINE}-unknown-linux-${LIBC} -+ echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" - exit ;; - k1om:Linux:*:*) -- echo ${UNAME_MACHINE}-unknown-linux-${LIBC} -+ echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" - exit ;; - m32r*:Linux:*:*) -- echo ${UNAME_MACHINE}-unknown-linux-${LIBC} -+ echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" - exit ;; - m68*:Linux:*:*) -- echo ${UNAME_MACHINE}-unknown-linux-${LIBC} -+ echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" - exit ;; - mips:Linux:*:* | mips64:Linux:*:*) -- eval $set_cc_for_build -- sed 's/^ //' << EOF >$dummy.c -+ set_cc_for_build -+ IS_GLIBC=0 -+ test x"${LIBC}" = xgnu && IS_GLIBC=1 -+ sed 's/^ //' << EOF > "$dummy.c" - #undef CPU -- #undef ${UNAME_MACHINE} -- #undef ${UNAME_MACHINE}el -+ #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) -- CPU=${UNAME_MACHINE}el -+ MIPS_ENDIAN=el - #else - #if defined(__MIPSEB__) || defined(__MIPSEB) || defined(_MIPSEB) || defined(MIPSEB) -- CPU=${UNAME_MACHINE} -+ MIPS_ENDIAN= - #else -- CPU= -+ MIPS_ENDIAN= - #endif - #endif - EOF -- eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep '^CPU'` -- test x"${CPU}" != x && { echo "${CPU}-unknown-linux-${LIBC}"; exit; } -+ eval "`$CC_FOR_BUILD -E "$dummy.c" 2>/dev/null | grep '^CPU\|^MIPS_ENDIAN\|^LIBCABI'`" -+ test "x$CPU" != x && { echo "$CPU${MIPS_ENDIAN}-unknown-linux-$LIBCABI"; exit; } - ;; - mips64el:Linux:*:*) -- echo ${UNAME_MACHINE}-unknown-linux-${LIBC} -+ echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" - exit ;; - openrisc*:Linux:*:*) -- echo or1k-unknown-linux-${LIBC} -+ echo or1k-unknown-linux-"$LIBC" - exit ;; - or32:Linux:*:* | or1k*:Linux:*:*) -- echo ${UNAME_MACHINE}-unknown-linux-${LIBC} -+ echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" - exit ;; - padre:Linux:*:*) -- echo sparc-unknown-linux-${LIBC} -+ echo sparc-unknown-linux-"$LIBC" - exit ;; - parisc64:Linux:*:* | hppa64:Linux:*:*) -- echo hppa64-unknown-linux-${LIBC} -+ echo hppa64-unknown-linux-"$LIBC" - exit ;; - parisc:Linux:*:* | hppa:Linux:*:*) - # Look for CPU level - case `grep '^cpu[^a-z]*:' /proc/cpuinfo 2>/dev/null | cut -d' ' -f2` in -- PA7*) echo hppa1.1-unknown-linux-${LIBC} ;; -- PA8*) echo hppa2.0-unknown-linux-${LIBC} ;; -- *) echo hppa-unknown-linux-${LIBC} ;; -+ PA7*) echo hppa1.1-unknown-linux-"$LIBC" ;; -+ PA8*) echo hppa2.0-unknown-linux-"$LIBC" ;; -+ *) echo hppa-unknown-linux-"$LIBC" ;; - esac - exit ;; - ppc64:Linux:*:*) -- echo powerpc64-unknown-linux-${LIBC} -+ echo powerpc64-unknown-linux-"$LIBC" - exit ;; - ppc:Linux:*:*) -- echo powerpc-unknown-linux-${LIBC} -+ echo powerpc-unknown-linux-"$LIBC" - exit ;; - ppc64le:Linux:*:*) -- echo powerpc64le-unknown-linux-${LIBC} -+ echo powerpc64le-unknown-linux-"$LIBC" - exit ;; - ppcle:Linux:*:*) -- echo powerpcle-unknown-linux-${LIBC} -+ echo powerpcle-unknown-linux-"$LIBC" - exit ;; - riscv32:Linux:*:* | riscv64:Linux:*:*) -- echo ${UNAME_MACHINE}-unknown-linux-${LIBC} -+ echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" - exit ;; - s390:Linux:*:* | s390x:Linux:*:*) -- echo ${UNAME_MACHINE}-ibm-linux-${LIBC} -+ echo "$UNAME_MACHINE"-ibm-linux-"$LIBC" - exit ;; - sh64*:Linux:*:*) -- echo ${UNAME_MACHINE}-unknown-linux-${LIBC} -+ echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" - exit ;; - sh*:Linux:*:*) -- echo ${UNAME_MACHINE}-unknown-linux-${LIBC} -+ echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" - exit ;; - sparc:Linux:*:* | sparc64:Linux:*:*) -- echo ${UNAME_MACHINE}-unknown-linux-${LIBC} -+ echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" - exit ;; - tile*:Linux:*:*) -- echo ${UNAME_MACHINE}-unknown-linux-${LIBC} -+ echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" - exit ;; - vax:Linux:*:*) -- echo ${UNAME_MACHINE}-dec-linux-${LIBC} -+ echo "$UNAME_MACHINE"-dec-linux-"$LIBC" - exit ;; - x86_64:Linux:*:*) -- echo ${UNAME_MACHINE}-pc-linux-${LIBC} -+ set_cc_for_build -+ LIBCABI=$LIBC -+ if test "$CC_FOR_BUILD" != no_compiler_found; then -+ if (echo '#ifdef __ILP32__'; echo IS_X32; echo '#endif') | \ -+ (CCOPTS="" $CC_FOR_BUILD -E - 2>/dev/null) | \ -+ grep IS_X32 >/dev/null -+ then -+ LIBCABI="$LIBC"x32 -+ fi -+ fi -+ echo "$UNAME_MACHINE"-pc-linux-"$LIBCABI" - exit ;; - xtensa*:Linux:*:*) -- echo ${UNAME_MACHINE}-unknown-linux-${LIBC} -+ echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" - exit ;; - i*86:DYNIX/ptx:4*:*) - # ptx 4.0 does uname -s correctly, with DYNIX/ptx in there. -@@ -1075,34 +1122,34 @@ - # 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. -- echo ${UNAME_MACHINE}-pc-sysv4.2uw${UNAME_VERSION} -+ echo "$UNAME_MACHINE"-pc-sysv4.2uw"$UNAME_VERSION" - exit ;; - i*86:OS/2:*:*) - # If we were able to find `uname', then EMX Unix compatibility - # is probably installed. -- echo ${UNAME_MACHINE}-pc-os2-emx -+ echo "$UNAME_MACHINE"-pc-os2-emx - exit ;; - i*86:XTS-300:*:STOP) -- echo ${UNAME_MACHINE}-unknown-stop -+ echo "$UNAME_MACHINE"-unknown-stop - exit ;; - i*86:atheos:*:*) -- echo ${UNAME_MACHINE}-unknown-atheos -+ echo "$UNAME_MACHINE"-unknown-atheos - exit ;; - i*86:syllable:*:*) -- echo ${UNAME_MACHINE}-pc-syllable -+ echo "$UNAME_MACHINE"-pc-syllable - exit ;; - i*86:LynxOS:2.*:* | i*86:LynxOS:3.[01]*:* | i*86:LynxOS:4.[02]*:*) -- echo i386-unknown-lynxos${UNAME_RELEASE} -+ echo i386-unknown-lynxos"$UNAME_RELEASE" - exit ;; - i*86:*DOS:*:*) -- echo ${UNAME_MACHINE}-pc-msdosdjgpp -+ echo "$UNAME_MACHINE"-pc-msdosdjgpp - exit ;; -- i*86:*:4.*:* | i*86:SYSTEM_V:4.*:*) -- UNAME_REL=`echo ${UNAME_RELEASE} | sed 's/\/MP$//'` -+ i*86:*:4.*:*) -+ UNAME_REL=`echo "$UNAME_RELEASE" | sed 's/\/MP$//'` - if grep Novell /usr/include/link.h >/dev/null 2>/dev/null; then -- echo ${UNAME_MACHINE}-univel-sysv${UNAME_REL} -+ echo "$UNAME_MACHINE"-univel-sysv"$UNAME_REL" - else -- echo ${UNAME_MACHINE}-pc-sysv${UNAME_REL} -+ echo "$UNAME_MACHINE"-pc-sysv"$UNAME_REL" - fi - exit ;; - i*86:*:5:[678]*) -@@ -1112,12 +1159,12 @@ - *Pentium) UNAME_MACHINE=i586 ;; - *Pent*|*Celeron) UNAME_MACHINE=i686 ;; - esac -- echo ${UNAME_MACHINE}-unknown-sysv${UNAME_RELEASE}${UNAME_SYSTEM}${UNAME_VERSION} -+ echo "$UNAME_MACHINE-unknown-sysv${UNAME_RELEASE}${UNAME_SYSTEM}${UNAME_VERSION}" - exit ;; - 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 -@@ -1127,9 +1174,9 @@ - && UNAME_MACHINE=i686 - (/bin/uname -X|grep '^Machine.*Pentium Pro' >/dev/null) \ - && UNAME_MACHINE=i686 -- echo ${UNAME_MACHINE}-pc-sco$UNAME_REL -+ echo "$UNAME_MACHINE"-pc-sco"$UNAME_REL" - else -- echo ${UNAME_MACHINE}-pc-sysv32 -+ echo "$UNAME_MACHINE"-pc-sysv32 - fi - exit ;; - pc:*:*:*) -@@ -1149,9 +1196,9 @@ - exit ;; - i860:*:4.*:*) # i860-SVR4 - if grep Stardent /usr/include/sys/uadmin.h >/dev/null 2>&1 ; then -- echo i860-stardent-sysv${UNAME_RELEASE} # Stardent Vistra i860-SVR4 -+ echo i860-stardent-sysv"$UNAME_RELEASE" # Stardent Vistra i860-SVR4 - else # Add other i860-SVR4 vendors below as they are discovered. -- echo i860-unknown-sysv${UNAME_RELEASE} # Unknown i860-SVR4 -+ echo i860-unknown-sysv"$UNAME_RELEASE" # Unknown i860-SVR4 - fi - exit ;; - mini*:CTIX:SYS*5:*) -@@ -1171,9 +1218,9 @@ - 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; } -+ && { 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; } ;; -+ && { 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; } ;; -@@ -1182,28 +1229,28 @@ - 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; } -+ && { 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; } -+ && { 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; } ;; -+ && { echo i586-ncr-sysv4.3"$OS_REL"; exit; } ;; - m68*:LynxOS:2.*:* | m68*:LynxOS:3.0*:*) -- echo m68k-unknown-lynxos${UNAME_RELEASE} -+ echo m68k-unknown-lynxos"$UNAME_RELEASE" - exit ;; - mc68030:UNIX_System_V:4.*:*) - echo m68k-atari-sysv4 - exit ;; - TSUNAMI:LynxOS:2.*:*) -- echo sparc-unknown-lynxos${UNAME_RELEASE} -+ echo sparc-unknown-lynxos"$UNAME_RELEASE" - exit ;; - rs6000:LynxOS:2.*:*) -- echo rs6000-unknown-lynxos${UNAME_RELEASE} -+ echo rs6000-unknown-lynxos"$UNAME_RELEASE" - exit ;; - PowerPC:LynxOS:2.*:* | PowerPC:LynxOS:3.[01]*:* | PowerPC:LynxOS:4.[02]*:*) -- echo powerpc-unknown-lynxos${UNAME_RELEASE} -+ echo powerpc-unknown-lynxos"$UNAME_RELEASE" - exit ;; - SM[BE]S:UNIX_SV:*:*) -- echo mips-dde-sysv${UNAME_RELEASE} -+ echo mips-dde-sysv"$UNAME_RELEASE" - exit ;; - RM*:ReliantUNIX-*:*:*) - echo mips-sni-sysv4 -@@ -1214,7 +1261,7 @@ - *:SINIX-*:*:*) - if uname -p 2>/dev/null >/dev/null ; then - UNAME_MACHINE=`(uname -p) 2>/dev/null` -- echo ${UNAME_MACHINE}-sni-sysv4 -+ echo "$UNAME_MACHINE"-sni-sysv4 - else - echo ns32k-sni-sysv - fi -@@ -1234,23 +1281,23 @@ - exit ;; - i*86:VOS:*:*) - # From Paul.Green@stratus.com. -- echo ${UNAME_MACHINE}-stratus-vos -+ echo "$UNAME_MACHINE"-stratus-vos - exit ;; - *:VOS:*:*) - # From Paul.Green@stratus.com. - echo hppa1.1-stratus-vos - exit ;; - mc68*:A/UX:*:*) -- echo m68k-apple-aux${UNAME_RELEASE} -+ echo m68k-apple-aux"$UNAME_RELEASE" - exit ;; - news*:NEWS-OS:6*:*) - echo mips-sony-newsos6 - exit ;; - R[34]000:*System_V*:*:* | R4000:UNIX_SYSV:*:* | R*000:UNIX_SV:*:*) -- if [ -d /usr/nec ]; then -- echo mips-nec-sysv${UNAME_RELEASE} -+ if test -d /usr/nec; then -+ echo mips-nec-sysv"$UNAME_RELEASE" - else -- echo mips-unknown-sysv${UNAME_RELEASE} -+ echo mips-unknown-sysv"$UNAME_RELEASE" - fi - exit ;; - BeBox:BeOS:*:*) # BeOS running on hardware made by Be, PPC only. -@@ -1269,60 +1316,71 @@ - echo x86_64-unknown-haiku - exit ;; - SX-4:SUPER-UX:*:*) -- echo sx4-nec-superux${UNAME_RELEASE} -+ echo sx4-nec-superux"$UNAME_RELEASE" - exit ;; - SX-5:SUPER-UX:*:*) -- echo sx5-nec-superux${UNAME_RELEASE} -+ echo sx5-nec-superux"$UNAME_RELEASE" - exit ;; - SX-6:SUPER-UX:*:*) -- echo sx6-nec-superux${UNAME_RELEASE} -+ echo sx6-nec-superux"$UNAME_RELEASE" - exit ;; - SX-7:SUPER-UX:*:*) -- echo sx7-nec-superux${UNAME_RELEASE} -+ echo sx7-nec-superux"$UNAME_RELEASE" - exit ;; - SX-8:SUPER-UX:*:*) -- echo sx8-nec-superux${UNAME_RELEASE} -+ echo sx8-nec-superux"$UNAME_RELEASE" - exit ;; - SX-8R:SUPER-UX:*:*) -- echo sx8r-nec-superux${UNAME_RELEASE} -+ echo sx8r-nec-superux"$UNAME_RELEASE" - exit ;; - SX-ACE:SUPER-UX:*:*) -- echo sxace-nec-superux${UNAME_RELEASE} -+ echo sxace-nec-superux"$UNAME_RELEASE" - exit ;; - Power*:Rhapsody:*:*) -- echo powerpc-apple-rhapsody${UNAME_RELEASE} -+ echo powerpc-apple-rhapsody"$UNAME_RELEASE" - exit ;; - *:Rhapsody:*:*) -- echo ${UNAME_MACHINE}-apple-rhapsody${UNAME_RELEASE} -+ echo "$UNAME_MACHINE"-apple-rhapsody"$UNAME_RELEASE" -+ exit ;; -+ arm64:Darwin:*:*) -+ echo aarch64-apple-darwin"$UNAME_RELEASE" - exit ;; - *:Darwin:*:*) -- UNAME_PROCESSOR=`uname -p` || UNAME_PROCESSOR=unknown -- eval $set_cc_for_build -- if test "$UNAME_PROCESSOR" = unknown ; then -- UNAME_PROCESSOR=powerpc -- fi -- if test `echo "$UNAME_RELEASE" | sed -e 's/\..*//'` -le 10 ; then -- if [ "$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 -+ 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 -- # Avoid executing cc on OS X 10.9, as it ships with a stub -- # that puts up a graphical alert prompting to install -- # developer tools. Any system running Mac OS X 10.7 or -- # later (Darwin 11 and later) is required to have a 64-bit -- # processor. This is not true of the ARM version of Darwin -- # that Apple uses in portable devices. -- UNAME_PROCESSOR=x86_64 -+ # uname -m returns i386 or x86_64 -+ UNAME_PROCESSOR=$UNAME_MACHINE - fi -- echo ${UNAME_PROCESSOR}-apple-darwin${UNAME_RELEASE} -+ echo "$UNAME_PROCESSOR"-apple-darwin"$UNAME_RELEASE" - exit ;; - *:procnto*:*:* | *:QNX:[0123456789]*:*) - UNAME_PROCESSOR=`uname -p` -@@ -1330,22 +1388,25 @@ - UNAME_PROCESSOR=i386 - UNAME_MACHINE=pc - fi -- echo ${UNAME_PROCESSOR}-${UNAME_MACHINE}-nto-qnx${UNAME_RELEASE} -+ echo "$UNAME_PROCESSOR"-"$UNAME_MACHINE"-nto-qnx"$UNAME_RELEASE" - exit ;; - *:QNX:*:4*) - echo i386-pc-qnx - exit ;; - NEO-*:NONSTOP_KERNEL:*:*) -- echo neo-tandem-nsk${UNAME_RELEASE} -+ echo neo-tandem-nsk"$UNAME_RELEASE" - exit ;; - NSE-*:NONSTOP_KERNEL:*:*) -- echo nse-tandem-nsk${UNAME_RELEASE} -+ echo nse-tandem-nsk"$UNAME_RELEASE" - exit ;; - NSR-*:NONSTOP_KERNEL:*:*) -- echo nsr-tandem-nsk${UNAME_RELEASE} -+ echo nsr-tandem-nsk"$UNAME_RELEASE" -+ exit ;; -+ NSV-*:NONSTOP_KERNEL:*:*) -+ echo nsv-tandem-nsk"$UNAME_RELEASE" - exit ;; - NSX-*:NONSTOP_KERNEL:*:*) -- echo nsx-tandem-nsk${UNAME_RELEASE} -+ echo nsx-tandem-nsk"$UNAME_RELEASE" - exit ;; - *:NonStop-UX:*:*) - echo mips-compaq-nonstopux -@@ -1354,18 +1415,19 @@ - echo bs2000-siemens-sysv - exit ;; - DS/*:UNIX_System_V:*:*) -- echo ${UNAME_MACHINE}-${UNAME_SYSTEM}-${UNAME_RELEASE} -+ echo "$UNAME_MACHINE"-"$UNAME_SYSTEM"-"$UNAME_RELEASE" - exit ;; - *:Plan9:*:*) - # "uname -m" is not consistent, so use $cputype instead. 386 - # is converted to i386 for consistency with other x86 - # operating systems. -+ # shellcheck disable=SC2154 - if test "$cputype" = 386; then - UNAME_MACHINE=i386 - else - UNAME_MACHINE="$cputype" - fi -- echo ${UNAME_MACHINE}-unknown-plan9 -+ echo "$UNAME_MACHINE"-unknown-plan9 - exit ;; - *:TOPS-10:*:*) - echo pdp10-unknown-tops10 -@@ -1386,14 +1448,14 @@ - echo pdp10-unknown-its - exit ;; - SEI:*:*:SEIUX) -- echo mips-sei-seiux${UNAME_RELEASE} -+ echo mips-sei-seiux"$UNAME_RELEASE" - exit ;; - *:DragonFly:*:*) -- echo ${UNAME_MACHINE}-unknown-dragonfly`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` -+ echo "$UNAME_MACHINE"-unknown-dragonfly"`echo "$UNAME_RELEASE"|sed -e 's/[-(].*//'`" - exit ;; - *:*VMS:*:*) - UNAME_MACHINE=`(uname -p) 2>/dev/null` -- case "${UNAME_MACHINE}" in -+ case "$UNAME_MACHINE" in - A*) echo alpha-dec-vms ; exit ;; - I*) echo ia64-dec-vms ; exit ;; - V*) echo vax-dec-vms ; exit ;; -@@ -1402,32 +1464,190 @@ - echo i386-pc-xenix - exit ;; - i*86:skyos:*:*) -- echo ${UNAME_MACHINE}-pc-skyos`echo ${UNAME_RELEASE} | sed -e 's/ .*$//'` -+ echo "$UNAME_MACHINE"-pc-skyos"`echo "$UNAME_RELEASE" | sed -e 's/ .*$//'`" - exit ;; - i*86:rdos:*:*) -- echo ${UNAME_MACHINE}-pc-rdos -+ echo "$UNAME_MACHINE"-pc-rdos - exit ;; - i*86:AROS:*:*) -- echo ${UNAME_MACHINE}-pc-aros -+ echo "$UNAME_MACHINE"-pc-aros - exit ;; - x86_64:VMkernel:*:*) -- echo ${UNAME_MACHINE}-unknown-esx -+ echo "$UNAME_MACHINE"-unknown-esx - exit ;; - amd64:Isilon\ OneFS:*:*) - echo x86_64-unknown-onefs - exit ;; -+ *:Unleashed:*:*) -+ echo "$UNAME_MACHINE"-unknown-unleashed"$UNAME_RELEASE" -+ exit ;; -+esac -+ -+# 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` - /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} -+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 'write-file-hooks 'time-stamp) -+# eval: (add-hook 'before-save-hook 'time-stamp) - # time-stamp-start: "timestamp='" - # time-stamp-format: "%:y-%02m-%02d" - # time-stamp-end: "'" -diff -ur libffi-3.3/config.sub libffi-3.3.new/config.sub ---- libffi-3.3/config.sub 2019-10-31 08:49:54.000000000 -0600 -+++ libffi-3.3.new/config.sub 2021-01-04 19:48:49.000000000 -0700 -@@ -1,8 +1,8 @@ - #! /bin/sh - # Configuration validation subroutine script. --# Copyright 1992-2017 Free Software Foundation, Inc. -+# Copyright 1992-2020 Free Software Foundation, Inc. - --timestamp='2017-04-02' -+timestamp='2020-08-17' - - # 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 -@@ -15,7 +15,7 @@ - # 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 . -+# 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 -@@ -33,7 +33,7 @@ - # Otherwise, we print the canonical config type on stdout and succeed. - - # You can get the latest version of this script from: --# http://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.sub -+# https://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.sub - - # This file is supposed to be the same for all GNU packages - # and recognize all the CPU types, system types and aliases -@@ -57,7 +57,7 @@ - - Canonicalize a configuration name. - --Operation modes: -+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 -@@ -67,7 +67,7 @@ - version="\ - GNU config.sub ($timestamp) - --Copyright 1992-2017 Free Software Foundation, Inc. -+Copyright 1992-2020 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." -@@ -89,12 +89,12 @@ - - ) # Use stdin as input. - break ;; - -* ) -- echo "$me: invalid option $1$help" -+ echo "$me: invalid option $1$help" >&2 - exit 1 ;; - - *local*) - # First pass through any local machine types. -- echo $1 -+ echo "$1" - exit ;; - - * ) -@@ -110,1252 +110,1167 @@ - exit 1;; - esac - --# Separate what the user gave into CPU-COMPANY and OS or KERNEL-OS (if any). --# Here we must recognize all the valid KERNEL-OS combinations. --maybe_os=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\2/'` --case $maybe_os in -- nto-qnx* | linux-gnu* | linux-android* | linux-dietlibc | linux-newlib* | \ -- linux-musl* | linux-uclibc* | uclinux-uclibc* | uclinux-gnu* | kfreebsd*-gnu* | \ -- knetbsd*-gnu* | netbsd*-gnu* | netbsd*-eabi* | \ -- kopensolaris*-gnu* | cloudabi*-eabi* | \ -- storm-chaos* | os2-emx* | rtmk-nova*) -- os=-$maybe_os -- basic_machine=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\1/'` -- ;; -- android-linux) -- os=-linux-android -- basic_machine=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\1/'`-unknown -- ;; -- *) -- basic_machine=`echo $1 | sed 's/-[^-]*$//'` -- if [ $basic_machine != $1 ] -- then os=`echo $1 | sed 's/.*-/-/'` -- else os=; fi -- ;; --esac -- --### Let's recognize common machines as not being operating systems so --### that things like config.sub decstation-3100 work. We also --### recognize some manufacturers as not being operating systems, so we --### can provide default operating systems below. --case $os in -- -sun*os*) -- # Prevent following clause from handling this invalid input. -- ;; -- -dec* | -mips* | -sequent* | -encore* | -pc532* | -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*) -- os= -- basic_machine=$1 -- ;; -- -bluegene*) -- os=-cnk -- ;; -- -sim | -cisco | -oki | -wec | -winbond) -- os= -- basic_machine=$1 -- ;; -- -scout) -- ;; -- -wrs) -- os=-vxworks -- basic_machine=$1 -- ;; -- -chorusos*) -- os=-chorusos -- basic_machine=$1 -- ;; -- -chorusrdb) -- os=-chorusrdb -- basic_machine=$1 -- ;; -- -hiux*) -- os=-hiuxwe2 -- ;; -- -sco6) -- os=-sco5v6 -- basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` -- ;; -- -sco5) -- os=-sco3.2v5 -- basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` -- ;; -- -sco4) -- os=-sco3.2v4 -- basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` -- ;; -- -sco3.2.[4-9]*) -- os=`echo $os | sed -e 's/sco3.2./sco3.2v/'` -- basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` -- ;; -- -sco3.2v[4-9]*) -- # Don't forget version if it is 3.2v4 or newer. -- basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` -- ;; -- -sco5v6*) -- # Don't forget version if it is 3.2v4 or newer. -- basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` -- ;; -- -sco*) -- os=-sco3.2v2 -- basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` -- ;; -- -udk*) -- basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` -- ;; -- -isc) -- os=-isc2.2 -- basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` -- ;; -- -clix*) -- basic_machine=clipper-intergraph -- ;; -- -isc*) -- basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` -- ;; -- -lynx*178) -- os=-lynxos178 -- ;; -- -lynx*5) -- os=-lynxos5 -- ;; -- -lynx*) -- os=-lynxos -+# Split fields of configuration type -+# shellcheck disable=SC2162 -+IFS="-" read field1 field2 field3 field4 <&2 -+ exit 1 - ;; -- -ptx*) -- basic_machine=`echo $1 | sed -e 's/86-.*/86-sequent/'` -+ *-*-*-*) -+ basic_machine=$field1-$field2 -+ basic_os=$field3-$field4 - ;; -- -windowsnt*) -- os=`echo $os | sed -e 's/windowsnt/winnt/'` -+ *-*-*) -+ # 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 - ;; -- -psos*) -- os=-psos -+ *-*) -+ # 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 -+ ;; -+ # 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 - ;; -- -mint | -mint[0-9]*) -- basic_machine=m68k-atari -- os=-mint -+ *) -+ # 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 aliases for certain CPU-COMPANY combinations. -+# Decode 1-component or ad-hoc basic machines - case $basic_machine in -- # Recognize the basic CPU types without company name. -- # Some are omitted here because they have special meanings below. -- 1750a | 580 \ -- | a29k \ -- | aarch64 | aarch64_be \ -- | alpha | alphaev[4-8] | alphaev56 | alphaev6[78] | alphapca5[67] \ -- | alpha64 | alpha64ev[4-8] | alpha64ev56 | alpha64ev6[78] | alpha64pca5[67] \ -- | am33_2.0 \ -- | arc | arceb \ -- | arm | arm[bl]e | arme[lb] | armv[2-8] | armv[3-8][lb] | armv7[arm] \ -- | avr | avr32 \ -- | ba \ -- | be32 | be64 \ -- | bfin \ -- | c4x | c8051 | clipper \ -- | d10v | d30v | dlx | dsp16xx \ -- | e2k | epiphany \ -- | fido | fr30 | frv | ft32 \ -- | h8300 | h8500 | hppa | hppa1.[01] | hppa2.0 | hppa2.0[nw] | hppa64 \ -- | hexagon \ -- | i370 | i860 | i960 | ia16 | ia64 \ -- | ip2k | iq2000 \ -- | k1om \ -- | le32 | le64 \ -- | lm32 \ -- | m32c | m32r | m32rle | m68000 | m68k | m88k \ -- | maxq | mb | microblaze | microblazeel | mcore | mep | metag \ -- | mips | mipsbe | mipseb | mipsel | mipsle \ -- | mips16 \ -- | mips64 | mips64el \ -- | mips64octeon | mips64octeonel \ -- | mips64orion | mips64orionel \ -- | mips64r5900 | mips64r5900el \ -- | mips64vr | mips64vrel \ -- | mips64vr4100 | mips64vr4100el \ -- | mips64vr4300 | mips64vr4300el \ -- | mips64vr5000 | mips64vr5000el \ -- | mips64vr5900 | mips64vr5900el \ -- | mipsisa32 | mipsisa32el \ -- | mipsisa32r2 | mipsisa32r2el \ -- | mipsisa32r6 | mipsisa32r6el \ -- | mipsisa64 | mipsisa64el \ -- | mipsisa64r2 | mipsisa64r2el \ -- | mipsisa64r6 | mipsisa64r6el \ -- | mipsisa64sb1 | mipsisa64sb1el \ -- | mipsisa64sr71k | mipsisa64sr71kel \ -- | mipsr5900 | mipsr5900el \ -- | mipstx39 | mipstx39el \ -- | mn10200 | mn10300 \ -- | moxie \ -- | mt \ -- | msp430 \ -- | nds32 | nds32le | nds32be \ -- | nios | nios2 | nios2eb | nios2el \ -- | ns16k | ns32k \ -- | open8 | or1k | or1knd | or32 \ -- | pdp10 | pdp11 | pj | pjl \ -- | powerpc | powerpc64 | powerpc64le | powerpcle \ -- | pru \ -- | pyramid \ -- | riscv32 | riscv64 \ -- | rl78 | rx \ -- | score \ -- | sh | sh[1234] | sh[24]a | sh[24]aeb | sh[23]e | sh[234]eb | sheb | shbe | shle | sh[1234]le | sh3ele \ -- | sh64 | sh64le \ -- | sparc | sparc64 | sparc64b | sparc64v | sparc86x | sparclet | sparclite \ -- | sparcv8 | sparcv9 | sparcv9b | sparcv9v \ -- | spu \ -- | tahoe | tic4x | tic54x | tic55x | tic6x | tic80 | tron \ -- | ubicom32 \ -- | v850 | v850e | v850e1 | v850e2 | v850es | v850e2v3 \ -- | visium \ -- | wasm32 \ -- | we32k \ -- | x86 | xc16x | xstormy16 | xtensa \ -- | z8k | z80) -- basic_machine=$basic_machine-unknown -- ;; -- c54x) -- basic_machine=tic54x-unknown -- ;; -- c55x) -- basic_machine=tic55x-unknown -- ;; -- c6x) -- basic_machine=tic6x-unknown -- ;; -- leon|leon[3-9]) -- basic_machine=sparc-$basic_machine -- ;; -- m6811 | m68hc11 | m6812 | m68hc12 | m68hcs12x | nvptx | picochip) -- basic_machine=$basic_machine-unknown -- os=-none -+ # 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 - ;; -- m88110 | m680[12346]0 | m683?2 | m68360 | m5200 | v70 | w65 | z8k) -+ op50n) -+ cpu=hppa1.1 -+ vendor=oki - ;; -- ms1) -- basic_machine=mt-unknown -+ op60c) -+ cpu=hppa1.1 -+ vendor=oki - ;; -- -- strongarm | thumb | xscale) -- basic_machine=arm-unknown -+ ibm*) -+ cpu=i370 -+ vendor=ibm - ;; -- xgate) -- basic_machine=$basic_machine-unknown -- os=-none -+ orion105) -+ cpu=clipper -+ vendor=highlevel - ;; -- xscaleeb) -- basic_machine=armeb-unknown -+ mac | mpw | mac-mpw) -+ cpu=m68k -+ vendor=apple - ;; -- -- xscaleel) -- basic_machine=armel-unknown -+ pmac | pmac-mpw) -+ cpu=powerpc -+ vendor=apple - ;; - -- # We use `pc' rather than `unknown' -- # because (1) that's what they normally are, and -- # (2) the word "unknown" tends to confuse beginning users. -- i*86 | x86_64) -- basic_machine=$basic_machine-pc -- ;; -- # Object if more than one company name word. -- *-*-*) -- echo Invalid configuration \`$1\': machine \`$basic_machine\' not recognized 1>&2 -- exit 1 -- ;; -- # Recognize the basic CPU types with company name. -- 580-* \ -- | a29k-* \ -- | aarch64-* | aarch64_be-* \ -- | alpha-* | alphaev[4-8]-* | alphaev56-* | alphaev6[78]-* \ -- | alpha64-* | alpha64ev[4-8]-* | alpha64ev56-* | alpha64ev6[78]-* \ -- | alphapca5[67]-* | alpha64pca5[67]-* | arc-* | arceb-* \ -- | arm-* | armbe-* | armle-* | armeb-* | armv*-* \ -- | avr-* | avr32-* \ -- | ba-* \ -- | be32-* | be64-* \ -- | bfin-* | bs2000-* \ -- | c[123]* | c30-* | [cjt]90-* | c4x-* \ -- | c8051-* | clipper-* | craynv-* | cydra-* \ -- | d10v-* | d30v-* | dlx-* \ -- | e2k-* | elxsi-* \ -- | f30[01]-* | f700-* | fido-* | fr30-* | frv-* | fx80-* \ -- | h8300-* | h8500-* \ -- | hppa-* | hppa1.[01]-* | hppa2.0-* | hppa2.0[nw]-* | hppa64-* \ -- | hexagon-* \ -- | i*86-* | i860-* | i960-* | ia16-* | ia64-* \ -- | ip2k-* | iq2000-* \ -- | k1om-* \ -- | le32-* | le64-* \ -- | lm32-* \ -- | m32c-* | m32r-* | m32rle-* \ -- | m68000-* | m680[012346]0-* | m68360-* | m683?2-* | m68k-* \ -- | m88110-* | m88k-* | maxq-* | mcore-* | metag-* \ -- | microblaze-* | microblazeel-* \ -- | mips-* | mipsbe-* | mipseb-* | mipsel-* | mipsle-* \ -- | mips16-* \ -- | mips64-* | mips64el-* \ -- | mips64octeon-* | mips64octeonel-* \ -- | mips64orion-* | mips64orionel-* \ -- | mips64r5900-* | mips64r5900el-* \ -- | mips64vr-* | mips64vrel-* \ -- | mips64vr4100-* | mips64vr4100el-* \ -- | mips64vr4300-* | mips64vr4300el-* \ -- | mips64vr5000-* | mips64vr5000el-* \ -- | mips64vr5900-* | mips64vr5900el-* \ -- | mipsisa32-* | mipsisa32el-* \ -- | mipsisa32r2-* | mipsisa32r2el-* \ -- | mipsisa32r6-* | mipsisa32r6el-* \ -- | mipsisa64-* | mipsisa64el-* \ -- | mipsisa64r2-* | mipsisa64r2el-* \ -- | mipsisa64r6-* | mipsisa64r6el-* \ -- | mipsisa64sb1-* | mipsisa64sb1el-* \ -- | mipsisa64sr71k-* | mipsisa64sr71kel-* \ -- | mipsr5900-* | mipsr5900el-* \ -- | mipstx39-* | mipstx39el-* \ -- | mmix-* \ -- | mt-* \ -- | msp430-* \ -- | nds32-* | nds32le-* | nds32be-* \ -- | nios-* | nios2-* | nios2eb-* | nios2el-* \ -- | none-* | np1-* | ns16k-* | ns32k-* \ -- | open8-* \ -- | or1k*-* \ -- | orion-* \ -- | pdp10-* | pdp11-* | pj-* | pjl-* | pn-* | power-* \ -- | powerpc-* | powerpc64-* | powerpc64le-* | powerpcle-* \ -- | pru-* \ -- | pyramid-* \ -- | riscv32-* | riscv64-* \ -- | rl78-* | romp-* | rs6000-* | rx-* \ -- | sh-* | sh[1234]-* | sh[24]a-* | sh[24]aeb-* | sh[23]e-* | sh[34]eb-* | sheb-* | shbe-* \ -- | shle-* | sh[1234]le-* | sh3ele-* | sh64-* | sh64le-* \ -- | sparc-* | sparc64-* | sparc64b-* | sparc64v-* | sparc86x-* | sparclet-* \ -- | sparclite-* \ -- | sparcv8-* | sparcv9-* | sparcv9b-* | sparcv9v-* | sv1-* | sx*-* \ -- | tahoe-* \ -- | tic30-* | tic4x-* | tic54x-* | tic55x-* | tic6x-* | tic80-* \ -- | tile*-* \ -- | tron-* \ -- | ubicom32-* \ -- | v850-* | v850e-* | v850e1-* | v850es-* | v850e2-* | v850e2v3-* \ -- | vax-* \ -- | visium-* \ -- | wasm32-* \ -- | we32k-* \ -- | x86-* | x86_64-* | xc16x-* | xps100-* \ -- | xstormy16-* | xtensa*-* \ -- | ymp-* \ -- | z8k-* | z80-*) -- ;; -- # Recognize the basic CPU types without company name, with glob match. -- xtensa*) -- basic_machine=$basic_machine-unknown -- ;; - # Recognize the various machine names and aliases which stand - # for a CPU type and a company and sometimes even an OS. -- 386bsd) -- basic_machine=i386-unknown -- os=-bsd -- ;; - 3b1 | 7300 | 7300-att | att-7300 | pc7300 | safari | unixpc) -- basic_machine=m68000-att -+ cpu=m68000 -+ vendor=att - ;; - 3b*) -- basic_machine=we32k-att -- ;; -- a29khif) -- basic_machine=a29k-amd -- os=-udi -- ;; -- abacus) -- basic_machine=abacus-unknown -- ;; -- adobe68k) -- basic_machine=m68010-adobe -- os=-scout -- ;; -- alliant | fx80) -- basic_machine=fx80-alliant -- ;; -- altos | altos3068) -- basic_machine=m68k-altos -- ;; -- am29k) -- basic_machine=a29k-none -- os=-bsd -- ;; -- amd64) -- basic_machine=x86_64-pc -- ;; -- amd64-*) -- basic_machine=x86_64-`echo $basic_machine | sed 's/^[^-]*-//'` -- ;; -- amdahl) -- basic_machine=580-amdahl -- os=-sysv -- ;; -- amiga | amiga-*) -- basic_machine=m68k-unknown -- ;; -- amigaos | amigados) -- basic_machine=m68k-unknown -- os=-amigaos -- ;; -- amigaunix | amix) -- basic_machine=m68k-unknown -- os=-sysv4 -- ;; -- apollo68) -- basic_machine=m68k-apollo -- os=-sysv -- ;; -- apollo68bsd) -- basic_machine=m68k-apollo -- os=-bsd -- ;; -- aros) -- basic_machine=i386-pc -- os=-aros -- ;; -- asmjs) -- basic_machine=asmjs-unknown -- ;; -- aux) -- basic_machine=m68k-apple -- os=-aux -- ;; -- balance) -- basic_machine=ns32k-sequent -- os=-dynix -- ;; -- blackfin) -- basic_machine=bfin-unknown -- os=-linux -- ;; -- blackfin-*) -- basic_machine=bfin-`echo $basic_machine | sed 's/^[^-]*-//'` -- os=-linux -+ cpu=we32k -+ vendor=att - ;; - bluegene*) -- basic_machine=powerpc-ibm -- os=-cnk -- ;; -- c54x-*) -- basic_machine=tic54x-`echo $basic_machine | sed 's/^[^-]*-//'` -- ;; -- c55x-*) -- basic_machine=tic55x-`echo $basic_machine | sed 's/^[^-]*-//'` -- ;; -- c6x-*) -- basic_machine=tic6x-`echo $basic_machine | sed 's/^[^-]*-//'` -- ;; -- c90) -- basic_machine=c90-cray -- os=-unicos -- ;; -- cegcc) -- basic_machine=arm-unknown -- os=-cegcc -- ;; -- convex-c1) -- basic_machine=c1-convex -- os=-bsd -- ;; -- convex-c2) -- basic_machine=c2-convex -- os=-bsd -- ;; -- convex-c32) -- basic_machine=c32-convex -- os=-bsd -- ;; -- convex-c34) -- basic_machine=c34-convex -- os=-bsd -- ;; -- convex-c38) -- basic_machine=c38-convex -- os=-bsd -- ;; -- cray | j90) -- basic_machine=j90-cray -- os=-unicos -- ;; -- craynv) -- basic_machine=craynv-cray -- os=-unicosmp -- ;; -- cr16 | cr16-*) -- basic_machine=cr16-unknown -- os=-elf -- ;; -- crds | unos) -- basic_machine=m68k-crds -- ;; -- crisv32 | crisv32-* | etraxfs*) -- basic_machine=crisv32-axis -- ;; -- cris | cris-* | etrax*) -- basic_machine=cris-axis -- ;; -- crx) -- basic_machine=crx-unknown -- os=-elf -- ;; -- da30 | da30-*) -- basic_machine=m68k-da30 -- ;; -- decstation | decstation-3100 | pmax | pmax-* | pmin | dec3100 | decstatn) -- basic_machine=mips-dec -+ cpu=powerpc -+ vendor=ibm -+ basic_os=cnk - ;; - decsystem10* | dec10*) -- basic_machine=pdp10-dec -- os=-tops10 -+ cpu=pdp10 -+ vendor=dec -+ basic_os=tops10 - ;; - decsystem20* | dec20*) -- basic_machine=pdp10-dec -- os=-tops20 -+ cpu=pdp10 -+ vendor=dec -+ basic_os=tops20 - ;; - delta | 3300 | motorola-3300 | motorola-delta \ - | 3300-motorola | delta-motorola) -- basic_machine=m68k-motorola -+ cpu=m68k -+ vendor=motorola - ;; -- delta88) -- basic_machine=m88k-motorola -- os=-sysv3 -- ;; -- dicos) -- basic_machine=i686-pc -- os=-dicos -- ;; -- djgpp) -- basic_machine=i586-pc -- os=-msdosdjgpp -- ;; -- dpx20 | dpx20-*) -- basic_machine=rs6000-bull -- os=-bosx -- ;; -- dpx2* | dpx2*-bull) -- basic_machine=m68k-bull -- os=-sysv3 -- ;; -- e500v[12]) -- basic_machine=powerpc-unknown -- os=$os"spe" -- ;; -- e500v[12]-*) -- basic_machine=powerpc-`echo $basic_machine | sed 's/^[^-]*-//'` -- os=$os"spe" -- ;; -- ebmon29k) -- basic_machine=a29k-amd -- os=-ebmon -- ;; -- elxsi) -- basic_machine=elxsi-elxsi -- os=-bsd -+ dpx2*) -+ cpu=m68k -+ vendor=bull -+ basic_os=sysv3 - ;; - encore | umax | mmax) -- basic_machine=ns32k-encore -+ cpu=ns32k -+ vendor=encore - ;; -- es1800 | OSE68k | ose68k | ose | OSE) -- basic_machine=m68k-ericsson -- os=-ose -+ elxsi) -+ cpu=elxsi -+ vendor=elxsi -+ basic_os=${basic_os:-bsd} - ;; - fx2800) -- basic_machine=i860-alliant -+ cpu=i860 -+ vendor=alliant - ;; - genix) -- basic_machine=ns32k-ns -- ;; -- gmicro) -- basic_machine=tron-gmicro -- os=-sysv -- ;; -- go32) -- basic_machine=i386-pc -- os=-go32 -+ cpu=ns32k -+ vendor=ns - ;; - h3050r* | hiux*) -- basic_machine=hppa1.1-hitachi -- os=-hiuxwe2 -- ;; -- h8300hms) -- basic_machine=h8300-hitachi -- os=-hms -- ;; -- h8300xray) -- basic_machine=h8300-hitachi -- os=-xray -- ;; -- h8500hms) -- basic_machine=h8500-hitachi -- os=-hms -- ;; -- harris) -- basic_machine=m88k-harris -- os=-sysv3 -- ;; -- hp300-*) -- basic_machine=m68k-hp -- ;; -- hp300bsd) -- basic_machine=m68k-hp -- os=-bsd -- ;; -- hp300hpux) -- basic_machine=m68k-hp -- os=-hpux -+ cpu=hppa1.1 -+ vendor=hitachi -+ basic_os=hiuxwe2 - ;; - hp3k9[0-9][0-9] | hp9[0-9][0-9]) -- basic_machine=hppa1.0-hp -+ cpu=hppa1.0 -+ vendor=hp - ;; - hp9k2[0-9][0-9] | hp9k31[0-9]) -- basic_machine=m68000-hp -+ cpu=m68000 -+ vendor=hp - ;; - hp9k3[2-9][0-9]) -- basic_machine=m68k-hp -+ cpu=m68k -+ vendor=hp - ;; - hp9k6[0-9][0-9] | hp6[0-9][0-9]) -- basic_machine=hppa1.0-hp -+ cpu=hppa1.0 -+ vendor=hp - ;; - hp9k7[0-79][0-9] | hp7[0-79][0-9]) -- basic_machine=hppa1.1-hp -+ cpu=hppa1.1 -+ vendor=hp - ;; - hp9k78[0-9] | hp78[0-9]) - # FIXME: really hppa2.0-hp -- basic_machine=hppa1.1-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 -- basic_machine=hppa1.1-hp -+ cpu=hppa1.1 -+ vendor=hp - ;; - hp9k8[0-9][13679] | hp8[0-9][13679]) -- basic_machine=hppa1.1-hp -+ cpu=hppa1.1 -+ vendor=hp - ;; - hp9k8[0-9][0-9] | hp8[0-9][0-9]) -- basic_machine=hppa1.0-hp -- ;; -- hppa-next) -- os=-nextstep3 -- ;; -- hppaosf) -- basic_machine=hppa1.1-hp -- os=-osf -- ;; -- hppro) -- basic_machine=hppa1.1-hp -- os=-proelf -- ;; -- i370-ibm* | ibm*) -- basic_machine=i370-ibm -+ cpu=hppa1.0 -+ vendor=hp - ;; - i*86v32) -- basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'` -- os=-sysv32 -+ cpu=`echo "$1" | sed -e 's/86.*/86/'` -+ vendor=pc -+ basic_os=sysv32 - ;; - i*86v4*) -- basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'` -- os=-sysv4 -+ cpu=`echo "$1" | sed -e 's/86.*/86/'` -+ vendor=pc -+ basic_os=sysv4 - ;; - i*86v) -- basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'` -- os=-sysv -+ cpu=`echo "$1" | sed -e 's/86.*/86/'` -+ vendor=pc -+ basic_os=sysv - ;; - i*86sol2) -- basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'` -- os=-solaris2 -- ;; -- i386mach) -- basic_machine=i386-mach -- os=-mach -- ;; -- i386-vsta | vsta) -- basic_machine=i386-unknown -- os=-vsta -+ 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) -- basic_machine=mips-sgi -- case $os in -- -irix*) -+ cpu=mips -+ vendor=sgi -+ case $basic_os in -+ irix*) - ;; - *) -- os=-irix4 -+ basic_os=irix4 - ;; - esac - ;; -- isi68 | isi) -- basic_machine=m68k-isi -- os=-sysv -- ;; -- leon-*|leon[3-9]-*) -- basic_machine=sparc-`echo $basic_machine | sed 's/-.*//'` -- ;; -- m68knommu) -- basic_machine=m68k-unknown -- os=-linux -- ;; -- m68knommu-*) -- basic_machine=m68k-`echo $basic_machine | sed 's/^[^-]*-//'` -- os=-linux -- ;; -- m88k-omron*) -- basic_machine=m88k-omron -- ;; -- magnum | m3230) -- basic_machine=mips-mips -- os=-sysv -- ;; -- merlin) -- basic_machine=ns32k-utek -- os=-sysv -- ;; -- microblaze*) -- basic_machine=microblaze-xilinx -- ;; -- mingw64) -- basic_machine=x86_64-pc -- os=-mingw64 -- ;; -- mingw32) -- basic_machine=i686-pc -- os=-mingw32 -- ;; -- mingw32ce) -- basic_machine=arm-unknown -- os=-mingw32ce -- ;; - miniframe) -- basic_machine=m68000-convergent -- ;; -- *mint | -mint[0-9]* | *MiNT | *MiNT[0-9]*) -- basic_machine=m68k-atari -- os=-mint -- ;; -- mips3*-*) -- basic_machine=`echo $basic_machine | sed -e 's/mips3/mips64/'` -+ cpu=m68000 -+ vendor=convergent - ;; -- mips3*) -- basic_machine=`echo $basic_machine | sed -e 's/mips3/mips64/'`-unknown -- ;; -- monitor) -- basic_machine=m68k-rom68k -- os=-coff -- ;; -- morphos) -- basic_machine=powerpc-unknown -- os=-morphos -- ;; -- moxiebox) -- basic_machine=moxie-unknown -- os=-moxiebox -- ;; -- msdos) -- basic_machine=i386-pc -- os=-msdos -- ;; -- ms1-*) -- basic_machine=`echo $basic_machine | sed -e 's/ms1-/mt-/'` -- ;; -- msys) -- basic_machine=i686-pc -- os=-msys -- ;; -- mvs) -- basic_machine=i370-ibm -- os=-mvs -- ;; -- nacl) -- basic_machine=le32-unknown -- os=-nacl -- ;; -- ncr3000) -- basic_machine=i486-ncr -- os=-sysv4 -- ;; -- netbsd386) -- basic_machine=i386-unknown -- os=-netbsd -- ;; -- netwinder) -- basic_machine=armv4l-rebel -- os=-linux -- ;; -- news | news700 | news800 | news900) -- basic_machine=m68k-sony -- os=-newsos -- ;; -- news1000) -- basic_machine=m68030-sony -- os=-newsos -+ *mint | mint[0-9]* | *MiNT | *MiNT[0-9]*) -+ cpu=m68k -+ vendor=atari -+ basic_os=mint - ;; - news-3600 | risc-news) -- basic_machine=mips-sony -- os=-newsos -- ;; -- necv70) -- basic_machine=v70-nec -- os=-sysv -- ;; -- next | m*-next ) -- basic_machine=m68k-next -- case $os in -- -nextstep* ) -+ cpu=mips -+ vendor=sony -+ basic_os=newsos -+ ;; -+ next | m*-next) -+ cpu=m68k -+ vendor=next -+ case $basic_os in -+ openstep*) -+ ;; -+ nextstep*) - ;; -- -ns2*) -- os=-nextstep2 -+ ns2*) -+ basic_os=nextstep2 - ;; - *) -- os=-nextstep3 -+ basic_os=nextstep3 - ;; - esac - ;; -- nh3000) -- basic_machine=m68k-harris -- os=-cxux -- ;; -- nh[45]000) -- basic_machine=m88k-harris -- os=-cxux -- ;; -- nindy960) -- basic_machine=i960-intel -- os=-nindy -- ;; -- mon960) -- basic_machine=i960-intel -- os=-mon960 -- ;; -- nonstopux) -- basic_machine=mips-compaq -- os=-nonstopux -- ;; - np1) -- basic_machine=np1-gould -- ;; -- neo-tandem) -- basic_machine=neo-tandem -- ;; -- nse-tandem) -- basic_machine=nse-tandem -- ;; -- nsr-tandem) -- basic_machine=nsr-tandem -- ;; -- nsx-tandem) -- basic_machine=nsx-tandem -+ cpu=np1 -+ vendor=gould - ;; - op50n-* | op60c-*) -- basic_machine=hppa1.1-oki -- os=-proelf -- ;; -- openrisc | openrisc-*) -- basic_machine=or32-unknown -- ;; -- os400) -- basic_machine=powerpc-ibm -- os=-os400 -- ;; -- OSE68000 | ose68000) -- basic_machine=m68000-ericsson -- os=-ose -- ;; -- os68k) -- basic_machine=m68k-none -- os=-os68k -+ cpu=hppa1.1 -+ vendor=oki -+ basic_os=proelf - ;; - pa-hitachi) -- basic_machine=hppa1.1-hitachi -- os=-hiuxwe2 -- ;; -- paragon) -- basic_machine=i860-intel -- os=-osf -- ;; -- parisc) -- basic_machine=hppa-unknown -- os=-linux -- ;; -- parisc-*) -- basic_machine=hppa-`echo $basic_machine | sed 's/^[^-]*-//'` -- os=-linux -+ cpu=hppa1.1 -+ vendor=hitachi -+ basic_os=hiuxwe2 - ;; - pbd) -- basic_machine=sparc-tti -+ cpu=sparc -+ vendor=tti - ;; - pbb) -- basic_machine=m68k-tti -- ;; -- pc532 | pc532-*) -- basic_machine=ns32k-pc532 -+ cpu=m68k -+ vendor=tti - ;; -- pc98) -- basic_machine=i386-pc -- ;; -- pc98-*) -- basic_machine=i386-`echo $basic_machine | sed 's/^[^-]*-//'` -+ pc532) -+ cpu=ns32k -+ vendor=pc532 - ;; -- pentium | p5 | k5 | k6 | nexgen | viac3) -- basic_machine=i586-pc -- ;; -- pentiumpro | p6 | 6x86 | athlon | athlon_*) -- basic_machine=i686-pc -- ;; -- pentiumii | pentium2 | pentiumiii | pentium3) -- basic_machine=i686-pc -+ pn) -+ cpu=pn -+ vendor=gould - ;; -- pentium4) -- basic_machine=i786-pc -+ power) -+ cpu=power -+ vendor=ibm - ;; -- pentium-* | p5-* | k5-* | k6-* | nexgen-* | viac3-*) -- basic_machine=i586-`echo $basic_machine | sed 's/^[^-]*-//'` -+ ps2) -+ cpu=i386 -+ vendor=ibm - ;; -- pentiumpro-* | p6-* | 6x86-* | athlon-*) -- basic_machine=i686-`echo $basic_machine | sed 's/^[^-]*-//'` -+ rm[46]00) -+ cpu=mips -+ vendor=siemens - ;; -- pentiumii-* | pentium2-* | pentiumiii-* | pentium3-*) -- basic_machine=i686-`echo $basic_machine | sed 's/^[^-]*-//'` -+ rtpc | rtpc-*) -+ cpu=romp -+ vendor=ibm - ;; -- pentium4-*) -- basic_machine=i786-`echo $basic_machine | sed 's/^[^-]*-//'` -+ sde) -+ cpu=mipsisa32 -+ vendor=sde -+ basic_os=${basic_os:-elf} -+ ;; -+ simso-wrs) -+ cpu=sparclite -+ vendor=wrs -+ basic_os=vxworks - ;; -- pn) -- basic_machine=pn-gould -+ tower | tower-32) -+ cpu=m68k -+ vendor=ncr - ;; -- power) basic_machine=power-ibm -+ vpp*|vx|vx-*) -+ cpu=f301 -+ vendor=fujitsu - ;; -- ppc | ppcbe) basic_machine=powerpc-unknown -+ w65) -+ cpu=w65 -+ vendor=wdc - ;; -- ppc-* | ppcbe-*) -- basic_machine=powerpc-`echo $basic_machine | sed 's/^[^-]*-//'` -- ;; -- ppcle | powerpclittle) -- basic_machine=powerpcle-unknown -+ w89k-*) -+ cpu=hppa1.1 -+ vendor=winbond -+ basic_os=proelf - ;; -- ppcle-* | powerpclittle-*) -- basic_machine=powerpcle-`echo $basic_machine | sed 's/^[^-]*-//'` -+ none) -+ cpu=none -+ vendor=none - ;; -- ppc64) basic_machine=powerpc64-unknown -+ leon|leon[3-9]) -+ cpu=sparc -+ vendor=$basic_machine - ;; -- ppc64-*) basic_machine=powerpc64-`echo $basic_machine | sed 's/^[^-]*-//'` -+ leon-*|leon[3-9]-*) -+ cpu=sparc -+ vendor=`echo "$basic_machine" | sed 's/-.*//'` - ;; -- ppc64le | powerpc64little) -- basic_machine=powerpc64le-unknown -+ -+ *-*) -+ # shellcheck disable=SC2162 -+ IFS="-" read cpu vendor <&2 -- exit 1 -+ # Recognize the canonical CPU types that are allowed with any -+ # company name. -+ case $cpu in -+ 1750a | 580 \ -+ | a29k \ -+ | aarch64 | aarch64_be \ -+ | abacus \ -+ | alpha | alphaev[4-8] | alphaev56 | alphaev6[78] \ -+ | alpha64 | alpha64ev[4-8] | alpha64ev56 | alpha64ev6[78] \ -+ | alphapca5[67] | alpha64pca5[67] \ -+ | am33_2.0 \ -+ | amdgcn \ -+ | arc | arceb \ -+ | arm | arm[lb]e | arme[lb] | armv* \ -+ | avr | avr32 \ -+ | asmjs \ -+ | ba \ -+ | be32 | be64 \ -+ | bfin | bpf | bs2000 \ -+ | c[123]* | c30 | [cjt]90 | c4x \ -+ | c8051 | clipper | craynv | csky | cydra \ -+ | d10v | d30v | dlx | dsp16xx \ -+ | e2k | elxsi | epiphany \ -+ | f30[01] | f700 | fido | fr30 | frv | ft32 | fx80 \ -+ | h8300 | h8500 \ -+ | hppa | hppa1.[01] | hppa2.0 | hppa2.0[nw] | hppa64 \ -+ | hexagon \ -+ | i370 | i*86 | i860 | i960 | ia16 | ia64 \ -+ | ip2k | iq2000 \ -+ | k1om \ -+ | le32 | le64 \ -+ | lm32 \ -+ | m32c | m32r | m32rle \ -+ | m5200 | m68000 | m680[012346]0 | m68360 | m683?2 | m68k \ -+ | m6811 | m68hc11 | m6812 | m68hc12 | m68hcs12x \ -+ | m88110 | m88k | maxq | mb | mcore | mep | metag \ -+ | microblaze | microblazeel \ -+ | mips | mipsbe | mipseb | mipsel | mipsle \ -+ | mips16 \ -+ | mips64 | mips64eb | mips64el \ -+ | mips64octeon | mips64octeonel \ -+ | mips64orion | mips64orionel \ -+ | mips64r5900 | mips64r5900el \ -+ | mips64vr | mips64vrel \ -+ | mips64vr4100 | mips64vr4100el \ -+ | mips64vr4300 | mips64vr4300el \ -+ | mips64vr5000 | mips64vr5000el \ -+ | mips64vr5900 | mips64vr5900el \ -+ | mipsisa32 | mipsisa32el \ -+ | mipsisa32r2 | mipsisa32r2el \ -+ | mipsisa32r6 | mipsisa32r6el \ -+ | mipsisa64 | mipsisa64el \ -+ | mipsisa64r2 | mipsisa64r2el \ -+ | mipsisa64r6 | mipsisa64r6el \ -+ | mipsisa64sb1 | mipsisa64sb1el \ -+ | mipsisa64sr71k | mipsisa64sr71kel \ -+ | mipsr5900 | mipsr5900el \ -+ | mipstx39 | mipstx39el \ -+ | mmix \ -+ | mn10200 | mn10300 \ -+ | moxie \ -+ | mt \ -+ | msp430 \ -+ | nds32 | nds32le | nds32be \ -+ | nfp \ -+ | nios | nios2 | nios2eb | nios2el \ -+ | none | np1 | ns16k | ns32k | nvptx \ -+ | open8 \ -+ | or1k* \ -+ | or32 \ -+ | orion \ -+ | picochip \ -+ | pdp10 | pdp11 | pj | pjl | pn | power \ -+ | powerpc | powerpc64 | powerpc64le | powerpcle | powerpcspe \ -+ | pru \ -+ | pyramid \ -+ | riscv | riscv32 | riscv64 \ -+ | rl78 | romp | rs6000 | rx \ -+ | s390 | s390x \ -+ | score \ -+ | sh | shl \ -+ | sh[1234] | sh[24]a | sh[24]ae[lb] | sh[23]e | she[lb] | sh[lb]e \ -+ | sh[1234]e[lb] | sh[12345][lb]e | sh[23]ele | sh64 | sh64le \ -+ | sparc | sparc64 | sparc64b | sparc64v | sparc86x | sparclet \ -+ | sparclite \ -+ | sparcv8 | sparcv9 | sparcv9b | sparcv9v | sv1 | sx* \ -+ | spu \ -+ | tahoe \ -+ | tic30 | tic4x | tic54x | tic55x | tic6x | tic80 \ -+ | tron \ -+ | ubicom32 \ -+ | v70 | v850 | v850e | v850e1 | v850es | v850e2 | v850e2v3 \ -+ | vax \ -+ | visium \ -+ | w65 \ -+ | wasm32 | wasm64 \ -+ | we32k \ -+ | x86 | x86_64 | xc16x | xgate | xps100 \ -+ | xstormy16 | xtensa* \ -+ | ymp \ -+ | z8k | z80) -+ ;; -+ -+ *) -+ echo Invalid configuration \`"$1"\': machine \`"$cpu-$vendor"\' not recognized 1>&2 -+ exit 1 -+ ;; -+ esac - ;; - esac - - # Here we canonicalize certain aliases for manufacturers. --case $basic_machine in -- *-digital*) -- basic_machine=`echo $basic_machine | sed 's/digital.*/dec/'` -+case $vendor in -+ digital*) -+ vendor=dec - ;; -- *-commodore*) -- basic_machine=`echo $basic_machine | sed 's/commodore.*/cbm/'` -+ commodore*) -+ vendor=cbm - ;; - *) - ;; -@@ -1363,203 +1278,215 @@ - - # Decode manufacturer-specific aliases for certain operating systems. - --if [ x"$os" != x"" ] -+if test x$basic_os != x - then --case $os in -- # First match some system type aliases -- # that might get confused with valid system types. -- # -solaris* is a basic system type, with this one exception. -- -auroraux) -- os=-auroraux -+ -+# First recognize some ad-hoc caes, 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|'` -+ ;; -+ nto-qnx*) -+ kernel=nto -+ os=`echo $basic_os | sed -e 's|nto-qnx|qnx|'` -+ ;; -+ *-*) -+ # shellcheck disable=SC2162 -+ IFS="-" read kernel os <&2 -- exit 1 -+ # No normalization, but not necessarily accepted, that comes below. - ;; - esac -+ - else - - # Here we handle the default operating systems that come with various machines. -@@ -1572,264 +1499,352 @@ - # will signal an error saying that MANUFACTURER isn't an operating - # system, and we'll never get to this point. - --case $basic_machine in -+kernel= -+case $cpu-$vendor in - score-*) -- os=-elf -+ os=elf - ;; - spu-*) -- os=-elf -+ os=elf - ;; - *-acorn) -- os=-riscix1.2 -+ os=riscix1.2 - ;; - arm*-rebel) -- os=-linux -+ kernel=linux -+ os=gnu - ;; - arm*-semi) -- os=-aout -+ os=aout - ;; - c4x-* | tic4x-*) -- os=-coff -+ os=coff - ;; - c8051-*) -- os=-elf -+ os=elf -+ ;; -+ clipper-intergraph) -+ os=clix - ;; - hexagon-*) -- os=-elf -+ os=elf - ;; - tic54x-*) -- os=-coff -+ os=coff - ;; - tic55x-*) -- os=-coff -+ os=coff - ;; - tic6x-*) -- os=-coff -+ os=coff - ;; - # This must come before the *-dec entry. - pdp10-*) -- os=-tops20 -+ os=tops20 - ;; - pdp11-*) -- os=-none -+ os=none - ;; - *-dec | vax-*) -- os=-ultrix4.2 -+ os=ultrix4.2 - ;; - m68*-apollo) -- os=-domain -+ os=domain - ;; - i386-sun) -- os=-sunos4.0.2 -+ os=sunos4.0.2 - ;; - m68000-sun) -- os=-sunos3 -+ os=sunos3 - ;; - m68*-cisco) -- os=-aout -+ os=aout - ;; - mep-*) -- os=-elf -+ os=elf - ;; - mips*-cisco) -- os=-elf -+ os=elf - ;; - mips*-*) -- os=-elf -+ os=elf - ;; - or32-*) -- os=-coff -+ os=coff - ;; - *-tti) # must be before sparc entry or we get the wrong os. -- os=-sysv3 -+ os=sysv3 - ;; - sparc-* | *-sun) -- os=-sunos4.1.1 -+ os=sunos4.1.1 - ;; - pru-*) -- os=-elf -+ os=elf - ;; - *-be) -- os=-beos -- ;; -- *-haiku) -- os=-haiku -+ os=beos - ;; - *-ibm) -- os=-aix -+ os=aix - ;; - *-knuth) -- os=-mmixware -+ os=mmixware - ;; - *-wec) -- os=-proelf -+ os=proelf - ;; - *-winbond) -- os=-proelf -+ os=proelf - ;; - *-oki) -- os=-proelf -+ os=proelf - ;; - *-hp) -- os=-hpux -+ os=hpux - ;; - *-hitachi) -- os=-hiux -+ os=hiux - ;; - i860-* | *-att | *-ncr | *-altos | *-motorola | *-convergent) -- os=-sysv -+ os=sysv - ;; - *-cbm) -- os=-amigaos -+ os=amigaos - ;; - *-dg) -- os=-dgux -+ os=dgux - ;; - *-dolphin) -- os=-sysv3 -+ os=sysv3 - ;; - m68k-ccur) -- os=-rtu -+ os=rtu - ;; - m88k-omron*) -- os=-luna -+ os=luna - ;; -- *-next ) -- os=-nextstep -+ *-next) -+ os=nextstep - ;; - *-sequent) -- os=-ptx -+ os=ptx - ;; - *-crds) -- os=-unos -+ os=unos - ;; - *-ns) -- os=-genix -+ os=genix - ;; - i370-*) -- os=-mvs -- ;; -- *-next) -- os=-nextstep3 -+ os=mvs - ;; - *-gould) -- os=-sysv -+ os=sysv - ;; - *-highlevel) -- os=-bsd -+ os=bsd - ;; - *-encore) -- os=-bsd -+ os=bsd - ;; - *-sgi) -- os=-irix -+ os=irix - ;; - *-siemens) -- os=-sysv4 -+ os=sysv4 - ;; - *-masscomp) -- os=-rtu -+ os=rtu - ;; - f30[01]-fujitsu | f700-fujitsu) -- os=-uxpv -+ os=uxpv - ;; - *-rom68k) -- os=-coff -+ os=coff - ;; - *-*bug) -- os=-coff -+ os=coff - ;; - *-apple) -- os=-macos -+ os=macos - ;; - *-atari*) -- os=-mint -+ os=mint -+ ;; -+ *-wrs) -+ os=vxworks - ;; - *) -- os=-none -+ os=none - ;; - esac -+ - fi - -+# Now, validate our (potentially fixed-up) OS. -+case $os in -+ # Sometimes we do "kernel-abi", so those need to count as OSes. -+ musl* | newlib* | uclibc*) -+ ;; -+ # Likewise for "kernel-libc" -+ eabi | eabihf | gnueabi | gnueabihf) -+ ;; -+ # Now accept the basic system types. -+ # The portable systems comes first. -+ # Each alternative MUST end in a * to match a version number. -+ gnu* | android* | bsd* | mach* | minix* | genix* | ultrix* | irix* \ -+ | *vms* | esix* | aix* | cnk* | sunos | sunos[34]* \ -+ | hpux* | unos* | osf* | luna* | dgux* | auroraux* | solaris* \ -+ | sym* | plan9* | psp* | sim* | xray* | os68k* | v88r* \ -+ | hiux* | abug | nacl* | netware* | windows* \ -+ | os9* | macos* | osx* | ios* \ -+ | mpw* | magic* | mmixware* | mon960* | lnews* \ -+ | amigaos* | amigados* | msdos* | newsos* | unicos* | aof* \ -+ | aos* | aros* | cloudabi* | sortix* | twizzler* \ -+ | nindy* | vxsim* | vxworks* | ebmon* | hms* | mvs* \ -+ | clix* | riscos* | uniplus* | iris* | isc* | rtu* | xenix* \ -+ | mirbsd* | netbsd* | dicos* | openedition* | ose* \ -+ | bitrig* | openbsd* | solidbsd* | libertybsd* | os108* \ -+ | ekkobsd* | freebsd* | riscix* | lynxos* | os400* \ -+ | bosx* | nextstep* | cxux* | aout* | elf* | oabi* \ -+ | ptx* | coff* | ecoff* | winnt* | domain* | vsta* \ -+ | udi* | lites* | ieee* | go32* | aux* | hcos* \ -+ | chorusrdb* | cegcc* | glidix* \ -+ | cygwin* | msys* | pe* | moss* | proelf* | rtems* \ -+ | midipix* | mingw32* | mingw64* | mint* \ -+ | uxpv* | beos* | mpeix* | udk* | moxiebox* \ -+ | interix* | uwin* | mks* | rhapsody* | darwin* \ -+ | openstep* | oskit* | conix* | pw32* | nonstopux* \ -+ | storm-chaos* | tops10* | tenex* | tops20* | its* \ -+ | os2* | vos* | palmos* | uclinux* | nucleus* | morphos* \ -+ | scout* | superux* | sysv* | rtmk* | tpf* | windiss* \ -+ | powermax* | dnix* | nx6 | nx7 | sei* | dragonfly* \ -+ | skyos* | haiku* | rdos* | toppers* | drops* | es* \ -+ | onefs* | tirtos* | phoenix* | fuchsia* | redox* | bme* \ -+ | midnightbsd* | amdhsa* | unleashed* | emscripten* | wasi* \ -+ | nsk* | powerunix* | genode* | zvmoe* ) -+ ;; -+ # This one is extra strict with allowed versions -+ sco3.2v2 | sco3.2v[4-9]* | sco5v6*) -+ # Don't forget version if it is 3.2v4 or newer. -+ ;; -+ none) -+ ;; -+ *) -+ echo Invalid configuration \`"$1"\': OS \`"$os"\' not recognized 1>&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-uclibc* ) -+ ;; -+ -dietlibc* | -newlib* | -musl* | -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*) -+ ;; -+ nto-qnx*) -+ ;; -+ *-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. --vendor=unknown --case $basic_machine in -- *-unknown) -- case $os in -- -riscix*) -+case $vendor in -+ unknown) -+ case $cpu-$os in -+ *-riscix*) - vendor=acorn - ;; -- -sunos*) -+ *-sunos*) - vendor=sun - ;; -- -cnk*|-aix*) -+ *-cnk* | *-aix*) - vendor=ibm - ;; -- -beos*) -+ *-beos*) - vendor=be - ;; -- -hpux*) -+ *-hpux*) - vendor=hp - ;; -- -mpeix*) -+ *-mpeix*) - vendor=hp - ;; -- -hiux*) -+ *-hiux*) - vendor=hitachi - ;; -- -unos*) -+ *-unos*) - vendor=crds - ;; -- -dgux*) -+ *-dgux*) - vendor=dg - ;; -- -luna*) -+ *-luna*) - vendor=omron - ;; -- -genix*) -+ *-genix*) - vendor=ns - ;; -- -mvs* | -opened*) -+ *-clix*) -+ vendor=intergraph -+ ;; -+ *-mvs* | *-opened*) -+ vendor=ibm -+ ;; -+ *-os400*) - vendor=ibm - ;; -- -os400*) -+ s390-* | s390x-*) - vendor=ibm - ;; -- -ptx*) -+ *-ptx*) - vendor=sequent - ;; -- -tpf*) -+ *-tpf*) - vendor=ibm - ;; -- -vxsim* | -vxworks* | -windiss*) -+ *-vxsim* | *-vxworks* | *-windiss*) - vendor=wrs - ;; -- -aux*) -+ *-aux*) - vendor=apple - ;; -- -hms*) -+ *-hms*) - vendor=hitachi - ;; -- -mpw* | -macos*) -+ *-mpw* | *-macos*) - vendor=apple - ;; -- -*mint | -mint[0-9]* | -*MiNT | -MiNT[0-9]*) -+ *-*mint | *-mint[0-9]* | *-*MiNT | *-MiNT[0-9]*) - vendor=atari - ;; -- -vos*) -+ *-vos*) - vendor=stratus - ;; - esac -- basic_machine=`echo $basic_machine | sed "s/unknown/$vendor/"` - ;; - esac - --echo $basic_machine$os -+echo "$cpu-$vendor-${kernel:+$kernel-}$os" - exit - - # Local variables: --# eval: (add-hook 'write-file-hooks 'time-stamp) -+# eval: (add-hook 'before-save-hook 'time-stamp) - # time-stamp-start: "timestamp='" - # time-stamp-format: "%:y-%02m-%02d" - # time-stamp-end: "'" -diff -ur libffi-3.3/configure libffi-3.3.new/configure ---- libffi-3.3/configure 2019-11-23 06:59:04.000000000 -0700 -+++ libffi-3.3.new/configure 2021-01-04 19:48:48.000000000 -0700 -@@ -3082,12 +3082,7 @@ - program_transform_name=`$as_echo "$program_transform_name" | sed "$ac_script"` - - if test x"${MISSING+set}" != xset; then -- case $am_aux_dir in -- *\ * | *\ *) -- MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;; -- *) -- MISSING="\${SHELL} $am_aux_dir/missing" ;; -- esac -+ MISSING="\${SHELL} '$am_aux_dir/missing'" - fi - # Use eval to expand $SHELL - if eval "$MISSING --is-lightweight"; then -@@ -8413,16 +8408,11 @@ - _lt_dar_allow_undefined='$wl-undefined ${wl}suppress' ;; - darwin1.*) - _lt_dar_allow_undefined='$wl-flat_namespace $wl-undefined ${wl}suppress' ;; -- darwin*) # darwin 5.x on -- # if running on 10.5 or later, the deployment target defaults -- # to the OS version, if on x86, and 10.4, the deployment -- # target defaults to 10.4. Don't you love it? -- case ${MACOSX_DEPLOYMENT_TARGET-10.0},$host in -- 10.0,*86*-darwin8*|10.0,*-darwin[91]*) -- _lt_dar_allow_undefined='$wl-undefined ${wl}dynamic_lookup' ;; -- 10.[012][,.]*) -+ darwin*) -+ case ${MACOSX_DEPLOYMENT_TARGET},$host in -+ 10.[012],*|,*powerpc*) - _lt_dar_allow_undefined='$wl-flat_namespace $wl-undefined ${wl}suppress' ;; -- 10.*) -+ *) - _lt_dar_allow_undefined='$wl-undefined ${wl}dynamic_lookup' ;; - esac - ;; -@@ -12042,9 +12032,6 @@ - # 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 -@@ -12053,7 +12040,7 @@ - # 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" -+ sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra" - fi - - # We used to test for /lib/ld.so.1 and disable shared libraries on -@@ -16007,9 +15994,6 @@ - # 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 -@@ -16018,7 +16002,7 @@ - # 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" -+ sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra" - fi - - # We used to test for /lib/ld.so.1 and disable shared libraries on -@@ -18411,6 +18395,59 @@ - ;; - esac - -+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether compiler supports pointer authentication" >&5 -+$as_echo_n "checking whether compiler supports pointer authentication... " >&6; } -+if ${libffi_cv_as_ptrauth+:} false; then : -+ $as_echo_n "(cached) " >&6 -+else -+ -+ libffi_cv_as_ptrauth=unknown -+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext -+/* end confdefs.h. */ -+ -+int -+main () -+{ -+ -+#ifdef __clang__ -+# if __has_feature(ptrauth_calls) -+# define HAVE_PTRAUTH 1 -+# endif -+#endif -+ -+#ifndef HAVE_PTRAUTH -+# error Pointer authentication not supported -+#endif -+ -+ ; -+ return 0; -+} -+_ACEOF -+if ac_fn_c_try_compile "$LINENO"; then : -+ libffi_cv_as_ptrauth=yes -+else -+ libffi_cv_as_ptrauth=no -+fi -+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -+ -+fi -+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $libffi_cv_as_ptrauth" >&5 -+$as_echo "$libffi_cv_as_ptrauth" >&6; } -+if test "x$libffi_cv_as_ptrauth" = xyes; then -+ -+$as_echo "#define HAVE_PTRAUTH 1" >>confdefs.h -+ -+fi -+ -+# Set additional defines for Apple Silicon. -+case "$target" in -+ aarch64-apple-darwin* | arm64-apple-darwin*) -+ -+$as_echo "#define FFI_TRAMPOLINE_WHOLE_DYLIB 1" >>confdefs.h -+ -+ ;; -+esac -+ - # On PaX enable kernels that have MPROTECT enable we can't use PROT_EXEC. - # Check whether --enable-pax_emutramp was given. - if test "${enable_pax_emutramp+set}" = set; then : -@@ -21144,7 +21181,9 @@ - { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 - $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} - as_fn_error $? "Something went wrong bootstrapping makefile fragments -- for automatic dependency tracking. Try re-running configure with the -+ 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; } -diff -ur libffi-3.3/configure.ac libffi-3.3.new/configure.ac ---- libffi-3.3/configure.ac 2019-11-23 06:58:22.000000000 -0700 -+++ libffi-3.3.new/configure.ac 2021-01-04 19:48:35.000000000 -0700 -@@ -176,6 +176,35 @@ - ;; - esac - -+AC_CACHE_CHECK([whether compiler supports pointer authentication], -+ libffi_cv_as_ptrauth, [ -+ libffi_cv_as_ptrauth=unknown -+ AC_TRY_COMPILE(,[ -+#ifdef __clang__ -+# if __has_feature(ptrauth_calls) -+# define HAVE_PTRAUTH 1 -+# endif -+#endif -+ -+#ifndef HAVE_PTRAUTH -+# error Pointer authentication not supported -+#endif -+ ], -+ [libffi_cv_as_ptrauth=yes], -+ [libffi_cv_as_ptrauth=no]) -+]) -+if test "x$libffi_cv_as_ptrauth" = xyes; then -+ AC_DEFINE(HAVE_PTRAUTH, 1, -+ [Define if your compiler supports pointer authentication.]) -+fi -+ -+# Set additional defines for Apple Silicon. -+case "$target" in -+ aarch64-apple-darwin* | arm64-apple-darwin*) -+ AC_DEFINE([FFI_TRAMPOLINE_WHOLE_DYLIB], 1, [Creating a separate libffi-trampolines.dylib and remapping the entire dylib]) -+ ;; -+esac -+ - # On PaX enable kernels that have MPROTECT enable we can't use PROT_EXEC. - AC_ARG_ENABLE(pax_emutramp, - [ --enable-pax_emutramp enable pax emulated trampolines, for we can't use PROT_EXEC], -diff -ur libffi-3.3/depcomp libffi-3.3.new/depcomp ---- libffi-3.3/depcomp 2019-11-01 03:30:05.000000000 -0600 -+++ libffi-3.3.new/depcomp 2021-01-04 19:48:49.000000000 -0700 -@@ -3,7 +3,7 @@ - - scriptversion=2018-03-07.03; # UTC - --# Copyright (C) 1999-2018 Free Software Foundation, Inc. -+# Copyright (C) 1999-2020 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 -diff -ur libffi-3.3/doc/Makefile.in libffi-3.3.new/doc/Makefile.in ---- libffi-3.3/doc/Makefile.in 2019-11-23 06:59:04.000000000 -0700 -+++ libffi-3.3.new/doc/Makefile.in 2021-01-04 19:48:49.000000000 -0700 -@@ -1,7 +1,7 @@ --# Makefile.in generated by automake 1.16.1 from Makefile.am. -+# Makefile.in generated by automake 1.16.3 from Makefile.am. - # @configure_input@ - --# Copyright (C) 1994-2018 Free Software Foundation, Inc. -+# Copyright (C) 1994-2020 Free Software Foundation, Inc. - - # This Makefile.in is free software; the Free Software Foundation - # gives unlimited permission to copy and/or distribute it, -diff -ur libffi-3.3/doc/mdate-sh libffi-3.3.new/doc/mdate-sh ---- libffi-3.3/doc/mdate-sh 2019-11-01 03:30:05.000000000 -0600 -+++ libffi-3.3.new/doc/mdate-sh 2021-01-04 19:48:49.000000000 -0700 -@@ -3,7 +3,7 @@ - - scriptversion=2018-03-07.03; # UTC - --# Copyright (C) 1995-2018 Free Software Foundation, Inc. -+# Copyright (C) 1995-2020 Free Software Foundation, Inc. - # written by Ulrich Drepper , June 1995 - # - # This program is free software; you can redistribute it and/or modify -diff -ur libffi-3.3/doc/texinfo.tex libffi-3.3.new/doc/texinfo.tex ---- libffi-3.3/doc/texinfo.tex 2019-11-22 10:27:54.000000000 -0700 -+++ libffi-3.3.new/doc/texinfo.tex 2021-01-04 19:48:49.000000000 -0700 -@@ -1,14 +1,11 @@ - % texinfo.tex -- TeX macros to handle Texinfo files. --% -+% - % Load plain if necessary, i.e., if running under initex. - \expandafter\ifx\csname fmtname\endcsname\relax\input plain\fi - % --\def\texinfoversion{2018-02-12.17} -+\def\texinfoversion{2020-10-24.12} - % --% Copyright 1985, 1986, 1988, 1990, 1991, 1992, 1993, 1994, 1995, --% 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, --% 2007, 2008, 2009, 2010, 2011, 2012, 2013, 2014, 2015, 2016, 2017, 2018 --% Free Software Foundation, Inc. -+% Copyright 1985, 1986, 1988, 1990-2020 Free Software Foundation, Inc. - % - % This texinfo.tex file is free software: you can redistribute it and/or - % modify it under the terms of the GNU General Public License as -@@ -36,7 +33,7 @@ - % The texinfo.tex in any given distribution could well be out - % of date, so if that's what you're using, please check. - % --% Send bug reports to bug-texinfo@gnu.org. Please include including a -+% Send bug reports to bug-texinfo@gnu.org. Please include a - % complete document in each bug report with which we can reproduce the - % problem. Patches are, of course, greatly appreciated. - % -@@ -182,7 +179,7 @@ - % Hyphenation fixes. - \hyphenation{ - Flor-i-da Ghost-script Ghost-view Mac-OS Post-Script -- auto-ma-ti-cal-ly ap-pen-dix bit-map bit-maps -+ ap-pen-dix bit-map bit-maps - data-base data-bases eshell fall-ing half-way long-est man-u-script - man-u-scripts mini-buf-fer mini-buf-fers over-view par-a-digm - par-a-digms rath-er rec-tan-gu-lar ro-bot-ics se-vere-ly set-up spa-ces -@@ -221,7 +218,7 @@ - % @errormsg{MSG}. Do the index-like expansions on MSG, but if things - % aren't perfect, it's not the end of the world, being an error message, - % after all. --% -+% - \def\errormsg{\begingroup \indexnofonts \doerrormsg} - \def\doerrormsg#1{\errmessage{#1}} - -@@ -244,17 +241,7 @@ - % - \def\finalout{\overfullrule=0pt } - --% Do @cropmarks to get crop marks. --% --\newif\ifcropmarks --\let\cropmarks = \cropmarkstrue --% --% Dimensions to add cropmarks at corners. --% Added by P. A. MacKay, 12 Nov. 1986 --% - \newdimen\outerhsize \newdimen\outervsize % set by the paper size routines --\newdimen\cornerlong \cornerlong=1pc --\newdimen\cornerthick \cornerthick=.3pt - \newdimen\topandbottommargin \topandbottommargin=.75in - - % Output a mark which sets \thischapter, \thissection and \thiscolor. -@@ -270,8 +257,8 @@ - - % \domark is called twice inside \chapmacro, to add one - % mark before the section break, and one after. --% In the second call \prevchapterdefs is the same as \lastchapterdefs, --% and \prevsectiondefs is the same as \lastsectiondefs. -+% In the second call \prevchapterdefs is the same as \currentchapterdefs, -+% and \prevsectiondefs is the same as \currentsectiondefs. - % Then if the page is not broken at the mark, some of the previous - % section appears on the page, and we can get the name of this section - % from \firstmark for @everyheadingmarks top. -@@ -279,11 +266,11 @@ - % - % See page 260 of The TeXbook. - \def\domark{% -- \toks0=\expandafter{\lastchapterdefs}% -- \toks2=\expandafter{\lastsectiondefs}% -+ \toks0=\expandafter{\currentchapterdefs}% -+ \toks2=\expandafter{\currentsectiondefs}% - \toks4=\expandafter{\prevchapterdefs}% - \toks6=\expandafter{\prevsectiondefs}% -- \toks8=\expandafter{\lastcolordefs}% -+ \toks8=\expandafter{\currentcolordefs}% - \mark{% - \the\toks0 \the\toks2 % 0: marks for @everyheadingmarks top - \noexpand\or \the\toks4 \the\toks6 % 1: for @everyheadingmarks bottom -@@ -300,19 +287,19 @@ - % @setcolor (or @url, or @link, etc.) between @contents and the very - % first @chapter. - \def\gettopheadingmarks{% -- \ifcase0\topmark\fi -+ \ifcase0\the\savedtopmark\fi - \ifx\thischapter\empty \ifcase0\firstmark\fi \fi - } - \def\getbottomheadingmarks{\ifcase1\botmark\fi} --\def\getcolormarks{\ifcase2\topmark\fi} -+\def\getcolormarks{\ifcase2\the\savedtopmark\fi} - - % Avoid "undefined control sequence" errors. --\def\lastchapterdefs{} --\def\lastsectiondefs{} --\def\lastsection{} -+\def\currentchapterdefs{} -+\def\currentsectiondefs{} -+\def\currentsection{} - \def\prevchapterdefs{} - \def\prevsectiondefs{} --\def\lastcolordefs{} -+\def\currentcolordefs{} - - % Margin to add to right of even pages, to left of odd pages. - \newdimen\bindingoffset -@@ -322,51 +309,61 @@ - % Main output routine. - % - \chardef\PAGE = 255 --\output = {\onepageout{\pagecontents\PAGE}} -+\newtoks\defaultoutput -+\defaultoutput = {\savetopmark\onepageout{\pagecontents\PAGE}} -+\output=\expandafter{\the\defaultoutput} - - \newbox\headlinebox - \newbox\footlinebox - -+% When outputting the double column layout for indices, an output routine -+% is run several times, which hides the original value of \topmark. This -+% can lead to a page heading being output and duplicating the chapter heading -+% of the index. Hence, save the contents of \topmark at the beginning of -+% the output routine. The saved contents are valid until we actually -+% \shipout a page. -+% -+% (We used to run a short output routine to actually set \topmark and -+% \firstmark to the right values, but if this was called with an empty page -+% containing whatsits for writing index entries, the whatsits would be thrown -+% away and the index auxiliary file would remain empty.) -+% -+\newtoks\savedtopmark -+\newif\iftopmarksaved -+\topmarksavedtrue -+\def\savetopmark{% -+ \iftopmarksaved\else -+ \global\savedtopmark=\expandafter{\topmark}% -+ \global\topmarksavedtrue -+ \fi -+} -+ - % \onepageout takes a vbox as an argument. --% \shipout a vbox for a single page, adding an optional header, footer, --% cropmarks, and footnote. This also causes index entries for this page --% to be written to the auxiliary files. -+% \shipout a vbox for a single page, adding an optional header, footer -+% and footnote. This also causes index entries for this page to be written -+% to the auxiliary files. - % - \def\onepageout#1{% -- \ifcropmarks \hoffset=0pt \else \hoffset=\normaloffset \fi -+ \hoffset=\normaloffset - % - \ifodd\pageno \advance\hoffset by \bindingoffset - \else \advance\hoffset by -\bindingoffset\fi - % -- % Common context changes for both heading and footing. -- % Do this outside of the \shipout so @code etc. will be expanded in -- % the headline as they should be, not taken literally (outputting ''code). -- \def\commmonheadfootline{\let\hsize=\txipagewidth \texinfochars} -+ \checkchapterpage - % - % Retrieve the information for the headings from the marks in the page, - % and call Plain TeX's \makeheadline and \makefootline, which use the - % values in \headline and \footline. - % -- % This is used to check if we are on the first page of a chapter. -- \ifcase1\topmark\fi -- \let\prevchaptername\thischaptername -- \ifcase0\firstmark\fi -- \let\curchaptername\thischaptername -+ % Common context changes for both heading and footing. -+ % Do this outside of the \shipout so @code etc. will be expanded in -+ % the headline as they should be, not taken literally (outputting ''code). -+ \def\commonheadfootline{\let\hsize=\txipagewidth \texinfochars} - % - \ifodd\pageno \getoddheadingmarks \else \getevenheadingmarks \fi -+ \global\setbox\headlinebox = \vbox{\commonheadfootline \makeheadline}% - \ifodd\pageno \getoddfootingmarks \else \getevenfootingmarks \fi -- % -- \ifx\curchaptername\prevchaptername -- \let\thischapterheading\thischapter -- \else -- % \thischapterheading is the same as \thischapter except it is blank -- % for the first page of a chapter. This is to prevent the chapter name -- % being shown twice. -- \def\thischapterheading{}% -- \fi -- % -- \global\setbox\headlinebox = \vbox{\commmonheadfootline \makeheadline}% -- \global\setbox\footlinebox = \vbox{\commmonheadfootline \makefootline}% -+ \global\setbox\footlinebox = \vbox{\commonheadfootline \makefootline}% - % - {% - % Set context for writing to auxiliary files like index files. -@@ -374,37 +371,12 @@ - % take effect in \write's, yet the group defined by the \vbox ends - % before the \shipout runs. - % -- \indexdummies % don't expand commands in the output. -- \normalturnoffactive % \ in index entries must not stay \, e.g., if -- % the page break happens to be in the middle of an example. -- % We don't want .vr (or whatever) entries like this: -- % \entry{{\indexbackslash }acronym}{32}{\code {\acronym}} -- % "\acronym" won't work when it's read back in; -- % it needs to be -- % {\code {{\backslashcurfont }acronym} -+ \atdummies % don't expand commands in the output. -+ \turnoffactive - \shipout\vbox{% - % Do this early so pdf references go to the beginning of the page. - \ifpdfmakepagedest \pdfdest name{\the\pageno} xyz\fi - % -- \ifcropmarks \vbox to \outervsize\bgroup -- \hsize = \outerhsize -- \vskip-\topandbottommargin -- \vtop to0pt{% -- \line{\ewtop\hfil\ewtop}% -- \nointerlineskip -- \line{% -- \vbox{\moveleft\cornerthick\nstop}% -- \hfill -- \vbox{\moveright\cornerthick\nstop}% -- }% -- \vss}% -- \vskip\topandbottommargin -- \line\bgroup -- \hfil % center the page within the outer (page) hsize. -- \ifodd\pageno\hskip\bindingoffset\fi -- \vbox\bgroup -- \fi -- % - \unvbox\headlinebox - \pagebody{#1}% - \ifdim\ht\footlinebox > 0pt -@@ -415,24 +387,9 @@ - \unvbox\footlinebox - \fi - % -- \ifcropmarks -- \egroup % end of \vbox\bgroup -- \hfil\egroup % end of (centering) \line\bgroup -- \vskip\topandbottommargin plus1fill minus1fill -- \boxmaxdepth = \cornerthick -- \vbox to0pt{\vss -- \line{% -- \vbox{\moveleft\cornerthick\nsbot}% -- \hfill -- \vbox{\moveright\cornerthick\nsbot}% -- }% -- \nointerlineskip -- \line{\ewbot\hfil\ewbot}% -- }% -- \egroup % \vbox from first cropmarks clause -- \fi -- }% end of \shipout\vbox -- }% end of group with \indexdummies -+ }% -+ }% -+ \global\topmarksavedfalse - \advancepageno - \ifnum\outputpenalty>-20000 \else\dosupereject\fi - } -@@ -451,17 +408,22 @@ - \ifr@ggedbottom \kern-\dimen@ \vfil \fi} - } - --% Here are the rules for the cropmarks. Note that they are --% offset so that the space between them is truly \outerhsize or \outervsize --% (P. A. MacKay, 12 November, 1986) --% --\def\ewtop{\vrule height\cornerthick depth0pt width\cornerlong} --\def\nstop{\vbox -- {\hrule height\cornerthick depth\cornerlong width\cornerthick}} --\def\ewbot{\vrule height0pt depth\cornerthick width\cornerlong} --\def\nsbot{\vbox -- {\hrule height\cornerlong depth\cornerthick width\cornerthick}} -- -+% Check if we are on the first page of a chapter. Used for printing headings. -+\newif\ifchapterpage -+\def\checkchapterpage{% -+ % Get the chapter that was current at the end of the last page -+ \ifcase1\the\savedtopmark\fi -+ \let\prevchaptername\thischaptername -+ % -+ \ifodd\pageno \getoddheadingmarks \else \getevenheadingmarks \fi -+ \let\curchaptername\thischaptername -+ % -+ \ifx\curchaptername\prevchaptername -+ \chapterpagefalse -+ \else -+ \chapterpagetrue -+ \fi -+} - - % Argument parsing - -@@ -487,11 +449,10 @@ - }% - } - --% First remove any @comment, then any @c comment. Also remove a @texinfoc --% comment (see \scanmacro for details). Pass the result on to \argcheckspaces. -+% First remove any @comment, then any @c comment. Pass the result on to -+% \argcheckspaces. - \def\argremovecomment#1\comment#2\ArgTerm{\argremovec #1\c\ArgTerm} --\def\argremovec#1\c#2\ArgTerm{\argremovetexinfoc #1\texinfoc\ArgTerm} --\def\argremovetexinfoc#1\texinfoc#2\ArgTerm{\argcheckspaces#1\^^M\ArgTerm} -+\def\argremovec#1\c#2\ArgTerm{\argcheckspaces#1\^^M\ArgTerm} - - % Each occurrence of `\^^M' or `\^^M' is replaced by a single space. - % -@@ -1050,7 +1011,7 @@ - \let\setfilename=\comment - - % @bye. --\outer\def\bye{\pagealignmacro\tracingstats=1\ptexend} -+\outer\def\bye{\chappager\pagelabels\tracingstats=1\ptexend} - - - \message{pdf,} -@@ -1092,7 +1053,7 @@ - tex.sprint( - string.format(string.char(0x5c) .. string.char(0x25) .. '03o' .. - string.char(0x5c) .. string.char(0x25) .. '03o', -- (c / 256), (c % 256))) -+ math.floor(c / 256), math.floor(c % 256))) - else - c = c - 0x10000 - local c_hi = c / 1024 + 0xd800 -@@ -1102,8 +1063,8 @@ - string.char(0x5c) .. string.char(0x25) .. '03o' .. - string.char(0x5c) .. string.char(0x25) .. '03o' .. - string.char(0x5c) .. string.char(0x25) .. '03o', -- (c_hi / 256), (c_hi % 256), -- (c_lo / 256), (c_lo % 256))) -+ math.floor(c_hi / 256), math.floor(c_hi % 256), -+ math.floor(c_lo / 256), math.floor(c_lo % 256))) - end - end - end -@@ -1116,15 +1077,19 @@ - function PDFescstr(str) - for c in string.bytes(str) do - if c <= 0x20 or c >= 0x80 or c == 0x28 or c == 0x29 or c == 0x5c then -- tex.sprint( -+ tex.sprint(-2, - string.format(string.char(0x5c) .. string.char(0x25) .. '03o', - c)) - else -- tex.sprint(string.char(c)) -+ tex.sprint(-2, string.char(c)) - end - end - end - } -+ % The -2 in the arguments here gives all the input to TeX catcode 12 -+ % (other) or 10 (space), preventing undefined control sequence errors. See -+ % https://lists.gnu.org/archive/html/bug-texinfo/2019-08/msg00031.html -+ % - \endgroup - \def\pdfescapestring#1{\directlua{PDFescstr('\luaescapestring{#1}')}} - \ifnum\luatexversion>84 -@@ -1163,11 +1128,60 @@ - \fi - \fi - -+\newif\ifpdforxetex -+\pdforxetexfalse -+\ifpdf -+ \pdforxetextrue -+\fi -+\ifx\XeTeXrevision\thisisundefined\else -+ \pdforxetextrue -+\fi -+ -+ -+% Output page labels information. -+% See PDF reference v.1.7 p.594, section 8.3.1. -+\ifpdf -+\def\pagelabels{% -+ \def\title{0 << /P (T-) /S /D >>}% -+ \edef\roman{\the\romancount << /S /r >>}% -+ \edef\arabic{\the\arabiccount << /S /D >>}% -+ % -+ % Page label ranges must be increasing. Remove any duplicates. -+ % (There is a slight chance of this being wrong if e.g. there is -+ % a @contents but no @titlepage, etc.) -+ % -+ \ifnum\romancount=0 \def\roman{}\fi -+ \ifnum\arabiccount=0 \def\title{}% -+ \else -+ \ifnum\romancount=\arabiccount \def\roman{}\fi -+ \fi -+ % -+ \ifnum\romancount<\arabiccount -+ \pdfcatalog{/PageLabels << /Nums [\title \roman \arabic ] >> }\relax -+ \else -+ \pdfcatalog{/PageLabels << /Nums [\title \arabic \roman ] >> }\relax -+ \fi -+} -+\else -+ \let\pagelabels\relax -+\fi -+ -+\newcount\pagecount \pagecount=0 -+\newcount\romancount \romancount=0 -+\newcount\arabiccount \arabiccount=0 -+\ifpdf -+ \let\ptxadvancepageno\advancepageno -+ \def\advancepageno{% -+ \ptxadvancepageno\global\advance\pagecount by 1 -+ } -+\fi -+ -+ - % PDF uses PostScript string constants for the names of xref targets, - % for display in the outlines, and in other places. Thus, we have to - % double any backslashes. Otherwise, a name like "\node" will be - % interpreted as a newline (\n), followed by o, d, e. Not good. --% -+% - % See http://www.ntg.nl/pipermail/ntg-pdftex/2004-July/000654.html and - % related messages. The final outcome is that it is up to the TeX user - % to double the backslashes and otherwise make the string valid, so -@@ -1219,7 +1233,7 @@ - % Set color, and create a mark which defines \thiscolor accordingly, - % so that \makeheadline knows which color to restore. - \def\setcolor#1{% -- \xdef\lastcolordefs{\gdef\noexpand\thiscolor{#1}}% -+ \xdef\currentcolordefs{\gdef\noexpand\thiscolor{#1}}% - \domark - \pdfsetcolor{#1}% - } -@@ -1227,7 +1241,7 @@ - \def\maincolor{\rgbBlack} - \pdfsetcolor{\maincolor} - \edef\thiscolor{\maincolor} -- \def\lastcolordefs{} -+ \def\currentcolordefs{} - % - \def\makefootline{% - \baselineskip24pt -@@ -1453,7 +1467,13 @@ - % subentries, which we calculated on our first read of the .toc above. - % - % We use the node names as the destinations. -+ % -+ % Currently we prefix the section name with the section number -+ % for chapter and appendix headings only in order to avoid too much -+ % horizontal space being required in the PDF viewer. - \def\numchapentry##1##2##3##4{% -+ \dopdfoutline{##2 ##1}{count-\expnumber{chap##2}}{##3}{##4}}% -+ \def\unnchapentry##1##2##3##4{% - \dopdfoutline{##1}{count-\expnumber{chap##2}}{##3}{##4}}% - \def\numsecentry##1##2##3##4{% - \dopdfoutline{##1}{count-\expnumber{sec##2}}{##3}{##4}}% -@@ -1472,7 +1492,7 @@ - % their "best" equivalent, based on the @documentencoding. Too - % much work for too little return. Just use the ASCII equivalents - % we use for the index sort strings. -- % -+ % - \indexnofonts - \setupdatafile - % We can have normal brace characters in the PDF outlines, unlike -@@ -1528,6 +1548,9 @@ - \startlink attr{/Border [0 0 0]}% - user{/Subtype /Link /A << /S /URI /URI (#1) >>}% - \endgroup} -+ % \pdfgettoks - Surround page numbers in #1 with @pdflink. #1 may -+ % be a simple number, or a list of numbers in the case of an index -+ % entry. - \def\pdfgettoks#1.{\setbox\boxA=\hbox{\toksA={#1.}\toksB={}\maketoks}} - \def\addtokens#1#2{\edef\addtoks{\noexpand#1={\the#1#2}}\addtoks} - \def\adn#1{\addtokens{\toksC}{#1}\global\countA=1\let\next=\maketoks} -@@ -1602,7 +1625,7 @@ - % Set color, and create a mark which defines \thiscolor accordingly, - % so that \makeheadline knows which color to restore. - \def\setcolor#1{% -- \xdef\lastcolordefs{\gdef\noexpand\thiscolor{#1}}% -+ \xdef\currentcolordefs{\gdef\noexpand\thiscolor{#1}}% - \domark - \pdfsetcolor{#1}% - } -@@ -1610,7 +1633,7 @@ - \def\maincolor{\rgbBlack} - \pdfsetcolor{\maincolor} - \edef\thiscolor{\maincolor} -- \def\lastcolordefs{} -+ \def\currentcolordefs{} - % - \def\makefootline{% - \baselineskip24pt -@@ -1692,9 +1715,13 @@ - % Therefore, we read toc only once. - % - % We use node names as destinations. -+ % -+ % Currently we prefix the section name with the section number -+ % for chapter and appendix headings only in order to avoid too much -+ % horizontal space being required in the PDF viewer. - \def\partentry##1##2##3##4{}% ignore parts in the outlines - \def\numchapentry##1##2##3##4{% -- \dopdfoutline{##1}{1}{##3}{##4}}% -+ \dopdfoutline{##2 ##1}{1}{##3}{##4}}% - \def\numsecentry##1##2##3##4{% - \dopdfoutline{##1}{2}{##3}{##4}}% - \def\numsubsecentry##1##2##3##4{% -@@ -1706,7 +1733,8 @@ - \let\appsecentry\numsecentry% - \let\appsubsecentry\numsubsecentry% - \let\appsubsubsecentry\numsubsubsecentry% -- \let\unnchapentry\numchapentry% -+ \def\unnchapentry##1##2##3##4{% -+ \dopdfoutline{##1}{1}{##3}{##4}}% - \let\unnsecentry\numsecentry% - \let\unnsubsecentry\numsubsecentry% - \let\unnsubsubsecentry\numsubsubsecentry% -@@ -2202,7 +2230,7 @@ - % A few fonts for @defun names and args. - \setfont\defbf\bfshape{10}{\magstep1}{OT1} - \setfont\deftt\ttshape{10}{\magstep1}{OT1TT} --\setfont\defsl\slshape{10}{\magstep1}{OT1TT} -+\setfont\defsl\slshape{10}{\magstep1}{OT1} - \setfont\defttsl\ttslshape{10}{\magstep1}{OT1TT} - \def\df{\let\ttfont=\deftt \let\bffont = \defbf - \let\ttslfont=\defttsl \let\slfont=\defsl \bf} -@@ -2350,7 +2378,7 @@ - % A few fonts for @defun names and args. - \setfont\defbf\bfshape{10}{\magstephalf}{OT1} - \setfont\deftt\ttshape{10}{\magstephalf}{OT1TT} --\setfont\defsl\slshape{10}{\magstephalf}{OT1TT} -+\setfont\defsl\slshape{10}{\magstephalf}{OT1} - \setfont\defttsl\ttslshape{10}{\magstephalf}{OT1TT} - \def\df{\let\ttfont=\deftt \let\bffont = \defbf - \let\slfont=\defsl \let\ttslfont=\defttsl \bf} -@@ -2519,7 +2547,7 @@ - \def\it{\fam=\itfam \setfontstyle{it}} - \def\sl{\fam=\slfam \setfontstyle{sl}} - \def\bf{\fam=\bffam \setfontstyle{bf}}\def\bfstylename{bf} --\def\tt{\fam=\ttfam \setfontstyle{tt}} -+\def\tt{\fam=\ttfam \setfontstyle{tt}}\def\ttstylename{tt} - - % Texinfo sort of supports the sans serif font style, which plain TeX does not. - % So we set up a \sf. -@@ -2753,7 +2781,7 @@ - } - - % Commands to set the quote options. --% -+% - \parseargdef\codequoteundirected{% - \def\temp{#1}% - \ifx\temp\onword -@@ -2794,7 +2822,7 @@ - % If we are in a monospaced environment, however, 1) always use \ttsl, - % and 2) do not add an italic correction. - \def\dosmartslant#1#2{% -- \ifusingtt -+ \ifusingtt - {{\ttsl #2}\let\next=\relax}% - {\def\next{{#1#2}\futurelet\next\smartitaliccorrection}}% - \next -@@ -2873,7 +2901,7 @@ - - % @t, explicit typewriter. - \def\t#1{% -- {\tt \rawbackslash \plainfrenchspacing #1}% -+ {\tt \plainfrenchspacing #1}% - \null - } - -@@ -2900,7 +2928,6 @@ - % Turn off hyphenation. - \nohyphenation - % -- \rawbackslash - \plainfrenchspacing - #1% - }% -@@ -2942,14 +2969,14 @@ - \gdef\codedash{\futurelet\next\codedashfinish} - \gdef\codedashfinish{% - \normaldash % always output the dash character itself. -- % -+ % - % Now, output a discretionary to allow a line break, unless - % (a) the next character is a -, or - % (b) the preceding character is a -. - % E.g., given --posix, we do not want to allow a break after either -. - % Given --foo-bar, we do want to allow a break between the - and the b. - \ifx\next\codedash \else -- \ifx\codedashprev\codedash -+ \ifx\codedashprev\codedash - \else \discretionary{}{}{}\fi - \fi - % we need the space after the = for the case when \next itself is a -@@ -3011,10 +3038,18 @@ - % arg (if given), and not the url (which is then just the link target). - \newif\ifurefurlonlylink - -+% The default \pretolerance setting stops the penalty inserted in -+% \urefallowbreak being a discouragement to line breaking. Set it to -+% a negative value for this paragraph only. Hopefully this does not -+% conflict with redefinitions of \par done elsewhere. -+\def\nopretolerance{% -+\pretolerance=-1 -+\def\par{\endgraf\pretolerance=100 \let\par\endgraf}% -+} -+ - % The main macro is \urefbreak, which allows breaking at expected --% places within the url. (There used to be another version, which --% didn't support automatic breaking.) --\def\urefbreak{\begingroup \urefcatcodes \dourefbreak} -+% places within the url. -+\def\urefbreak{\nopretolerance \begingroup \urefcatcodes \dourefbreak} - \let\uref=\urefbreak - % - \def\dourefbreak#1{\urefbreakfinish #1,,,\finish} -@@ -3031,7 +3066,7 @@ - % For pdfTeX and LuaTeX - \ifurefurlonlylink - % PDF plus option to not display url, show just arg -- \unhbox0 -+ \unhbox0 - \else - % PDF, normally display both arg and url for consistency, - % visibility, if the pdf is eventually used to print, etc. -@@ -3044,7 +3079,7 @@ - % For XeTeX - \ifurefurlonlylink - % PDF plus option to not display url, show just arg -- \unhbox0 -+ \unhbox0 - \else - % PDF, normally display both arg and url for consistency, - % visibility, if the pdf is eventually used to print, etc. -@@ -3087,41 +3122,33 @@ - \global\def/{\normalslash} - } - --% we put a little stretch before and after the breakable chars, to help --% line breaking of long url's. The unequal skips make look better in --% cmtt at least, especially for dots. --\def\urefprestretchamount{.13em} --\def\urefpoststretchamount{.1em} --\def\urefprestretch{\urefprebreak \hskip0pt plus\urefprestretchamount\relax} --\def\urefpoststretch{\urefpostbreak \hskip0pt plus\urefprestretchamount\relax} --% --\def\urefcodeamp{\urefprestretch \&\urefpoststretch} --\def\urefcodedot{\urefprestretch .\urefpoststretch} --\def\urefcodehash{\urefprestretch \#\urefpoststretch} --\def\urefcodequest{\urefprestretch ?\urefpoststretch} -+\def\urefcodeamp{\urefprebreak \&\urefpostbreak} -+\def\urefcodedot{\urefprebreak .\urefpostbreak} -+\def\urefcodehash{\urefprebreak \#\urefpostbreak} -+\def\urefcodequest{\urefprebreak ?\urefpostbreak} - \def\urefcodeslash{\futurelet\next\urefcodeslashfinish} - { - \catcode`\/=\active - \global\def\urefcodeslashfinish{% -- \urefprestretch \slashChar -+ \urefprebreak \slashChar - % Allow line break only after the final / in a sequence of - % slashes, to avoid line break between the slashes in http://. -- \ifx\next/\else \urefpoststretch \fi -+ \ifx\next/\else \urefpostbreak \fi - } - } - --% One more complication: by default we'll break after the special --% characters, but some people like to break before the special chars, so --% allow that. Also allow no breaking at all, for manual control. --% -+% By default we'll break after the special characters, but some people like to -+% break before the special chars, so allow that. Also allow no breaking at -+% all, for manual control. -+% - \parseargdef\urefbreakstyle{% - \def\txiarg{#1}% - \ifx\txiarg\wordnone - \def\urefprebreak{\nobreak}\def\urefpostbreak{\nobreak} - \else\ifx\txiarg\wordbefore -- \def\urefprebreak{\allowbreak}\def\urefpostbreak{\nobreak} -+ \def\urefprebreak{\urefallowbreak}\def\urefpostbreak{\nobreak} - \else\ifx\txiarg\wordafter -- \def\urefprebreak{\nobreak}\def\urefpostbreak{\allowbreak} -+ \def\urefprebreak{\nobreak}\def\urefpostbreak{\urefallowbreak} - \else - \errhelp = \EMsimple - \errmessage{Unknown @urefbreakstyle setting `\txiarg'}% -@@ -3131,6 +3158,19 @@ - \def\wordbefore{before} - \def\wordnone{none} - -+% Allow a ragged right output to aid breaking long URL's. There can -+% be a break at the \allowbreak with no extra glue (if the existing stretch in -+% the line is sufficient), a break at the \penalty with extra glue added -+% at the end of the line, or no break at all here. -+% Changing the value of the penalty and/or the amount of stretch affects how -+% preferable one choice is over the other. -+\def\urefallowbreak{% -+ \penalty0\relax -+ \hskip 0pt plus 2 em\relax -+ \penalty1000\relax -+ \hskip 0pt plus -2 em\relax -+} -+ - \urefbreakstyle after - - % @url synonym for @uref, since that's how everyone uses it. -@@ -3141,7 +3181,7 @@ - % So now @email is just like @uref, unless we are pdf. - % - %\def\email#1{\angleleft{\tt #1}\angleright} --\ifpdf -+\ifpdforxetex - \def\email#1{\doemail#1,,\finish} - \def\doemail#1,#2,#3\finish{\begingroup - \unsepspaces -@@ -3151,18 +3191,7 @@ - \endlink - \endgroup} - \else -- \ifx\XeTeXrevision\thisisundefined -- \let\email=\uref -- \else -- \def\email#1{\doemail#1,,\finish} -- \def\doemail#1,#2,#3\finish{\begingroup -- \unsepspaces -- \pdfurl{mailto:#1}% -- \setbox0 = \hbox{\ignorespaces #2}% -- \ifdim\wd0>0pt\unhbox0\else\code{#1}\fi -- \endlink -- \endgroup} -- \fi -+ \let\email=\uref - \fi - - % @kbdinputstyle -- arg is `distinct' (@kbd uses slanted tty font always), -@@ -3335,10 +3364,29 @@ - \def\sup{\ifmmode \expandafter\ptexsp \else \expandafter\finishsup\fi} - \def\finishsup#1{$\ptexsp{\hbox{\switchtolllsize #1}}$}% - -+% provide this command from LaTeX as it is very common -+\def\frac#1#2{{{#1}\over{#2}}} -+ -+% @displaymath. -+% \globaldefs is needed to recognize the end lines in \tex and -+% \end tex. Set \thisenv as @end displaymath is seen before @end tex. -+{\obeylines -+\globaldefs=1 -+\envdef\displaymath{% -+\tex -+\def\thisenv{\displaymath}% -+$$% -+} -+ -+\def\Edisplaymath{$$ -+\def\thisenv{\tex}% -+\end tex -+}} -+ - % @inlinefmt{FMTNAME,PROCESSED-TEXT} and @inlineraw{FMTNAME,RAW-TEXT}. - % Ignore unless FMTNAME == tex; then it is like @iftex and @tex, - % except specified as a normal braced arg, so no newlines to worry about. --% -+% - \def\outfmtnametex{tex} - % - \long\def\inlinefmt#1{\doinlinefmt #1,\finish} -@@ -3346,7 +3394,7 @@ - \def\inlinefmtname{#1}% - \ifx\inlinefmtname\outfmtnametex \ignorespaces #2\fi - } --% -+% - % @inlinefmtifelse{FMTNAME,THEN-TEXT,ELSE-TEXT} expands THEN-TEXT if - % FMTNAME is tex, else ELSE-TEXT. - \long\def\inlinefmtifelse#1{\doinlinefmtifelse #1,,,\finish} -@@ -3362,7 +3410,7 @@ - % *right* brace they would have to use a command anyway, so they may as - % well use a command to get a left brace too. We could re-use the - % delimiter character idea from \verb, but it seems like overkill. --% -+% - \long\def\inlineraw{\tex \doinlineraw} - \long\def\doinlineraw#1{\doinlinerawtwo #1,\finish} - \def\doinlinerawtwo#1,#2,\finish{% -@@ -3539,7 +3587,7 @@ - - % @pounds{} is a sterling sign, which Knuth put in the CM italic font. - % --\def\pounds{{\it\$}} -+\def\pounds{\ifmonospace{\ecfont\char"BF}\else{\it\$}\fi} - - % @euro{} comes from a separate font, depending on the current style. - % We use the free feym* fonts from the eurosym package by Henrik -@@ -3639,7 +3687,7 @@ - % for non-CM glyphs. That is ec* for regular text and tc* for the text - % companion symbols (LaTeX TS1 encoding). Both are part of the ec - % package and follow the same conventions. --% -+% - \def\ecfont{\etcfont{e}} - \def\tcfont{\etcfont{t}} - % -@@ -3688,11 +3736,19 @@ - \fi - - % Quotes. --\chardef\quotedblleft="5C --\chardef\quotedblright=`\" - \chardef\quoteleft=`\` - \chardef\quoteright=`\' - -+% only change font for tt for correct kerning and to avoid using -+% \ecfont unless necessary. -+\def\quotedblleft{% -+ \ifmonospace{\ecfont\char"10}\else{\char"5C}\fi -+} -+ -+\def\quotedblright{% -+ \ifmonospace{\ecfont\char"11}\else{\char`\"}\fi -+} -+ - - \message{page headings,} - -@@ -3711,7 +3767,7 @@ - after the title page.}}% - \def\setshortcontentsaftertitlepage{% - \errmessage{@setshortcontentsaftertitlepage has been removed as a Texinfo -- command; move your @shortcontents and @contents commands if you -+ command; move your @shortcontents and @contents commands if you - want the contents after the title page.}}% - - \parseargdef\shorttitlepage{% -@@ -3766,7 +3822,7 @@ - % don't worry much about spacing, ragged right. This should be used - % inside a \vbox, and fonts need to be set appropriately first. \par should - % be specified before the end of the \vbox, since a vbox is a group. --% -+% - \def\raggedtitlesettings{% - \rm - \hyphenpenalty=10000 -@@ -3814,12 +3870,19 @@ - - \newtoks\evenheadline % headline on even pages - \newtoks\oddheadline % headline on odd pages -+\newtoks\evenchapheadline% headline on even pages with a new chapter -+\newtoks\oddchapheadline % headline on odd pages with a new chapter - \newtoks\evenfootline % footline on even pages - \newtoks\oddfootline % footline on odd pages - - % Now make \makeheadline and \makefootline in Plain TeX use those variables --\headline={{\textfonts\rm \ifodd\pageno \the\oddheadline -- \else \the\evenheadline \fi}} -+\headline={{\textfonts\rm -+ \ifchapterpage -+ \ifodd\pageno\the\oddchapheadline\else\the\evenchapheadline\fi -+ \else -+ \ifodd\pageno\the\oddheadline\else\the\evenheadline\fi -+ \fi}} -+ - \footline={{\textfonts\rm \ifodd\pageno \the\oddfootline - \else \the\evenfootline \fi}\HEADINGShook} - \let\HEADINGShook=\relax -@@ -3835,12 +3898,14 @@ - \def\evenheading{\parsearg\evenheadingxxx} - \def\evenheadingxxx #1{\evenheadingyyy #1\|\|\|\|\finish} - \def\evenheadingyyy #1\|#2\|#3\|#4\finish{% --\global\evenheadline={\rlap{\centerline{#2}}\line{#1\hfil#3}}} -+ \global\evenheadline={\rlap{\centerline{#2}}\line{#1\hfil#3}} -+ \global\evenchapheadline=\evenheadline} - - \def\oddheading{\parsearg\oddheadingxxx} - \def\oddheadingxxx #1{\oddheadingyyy #1\|\|\|\|\finish} - \def\oddheadingyyy #1\|#2\|#3\|#4\finish{% --\global\oddheadline={\rlap{\centerline{#2}}\line{#1\hfil#3}}} -+ \global\oddheadline={\rlap{\centerline{#2}}\line{#1\hfil#3}}% -+ \global\oddchapheadline=\oddheadline} - - \parseargdef\everyheading{\oddheadingxxx{#1}\evenheadingxxx{#1}}% - -@@ -3907,37 +3972,34 @@ - \parseargdef\headings{\csname HEADINGS#1\endcsname} - - \def\headingsoff{% non-global headings elimination -- \evenheadline={\hfil}\evenfootline={\hfil}% -- \oddheadline={\hfil}\oddfootline={\hfil}% -+ \evenheadline={\hfil}\evenfootline={\hfil}\evenchapheadline={\hfil}% -+ \oddheadline={\hfil}\oddfootline={\hfil}\oddchapheadline={\hfil}% - } - - \def\HEADINGSoff{{\globaldefs=1 \headingsoff}} % global setting - \HEADINGSoff % it's the default - - % When we turn headings on, set the page number to 1. -+\def\pageone{ -+ \global\pageno=1 -+ \global\arabiccount = \pagecount -+} -+ - % For double-sided printing, put current file name in lower left corner, - % chapter name on inside top of right hand pages, document - % title on inside top of left hand pages, and page numbers on outside top - % edge of all pages. - \def\HEADINGSdouble{% --\global\pageno=1 --\global\evenfootline={\hfil} --\global\oddfootline={\hfil} --\global\evenheadline={\line{\folio\hfil\thistitle}} --\global\oddheadline={\line{\thischapterheading\hfil\folio}} --\global\let\contentsalignmacro = \chapoddpage -+\pageone -+\HEADINGSdoublex - } - \let\contentsalignmacro = \chappager - - % For single-sided printing, chapter title goes across top left of page, - % page number on top right. - \def\HEADINGSsingle{% --\global\pageno=1 --\global\evenfootline={\hfil} --\global\oddfootline={\hfil} --\global\evenheadline={\line{\thischapterheading\hfil\folio}} --\global\oddheadline={\line{\thischapterheading\hfil\folio}} --\global\let\contentsalignmacro = \chappager -+\pageone -+\HEADINGSsinglex - } - \def\HEADINGSon{\HEADINGSdouble} - -@@ -3947,7 +4009,9 @@ - \global\evenfootline={\hfil} - \global\oddfootline={\hfil} - \global\evenheadline={\line{\folio\hfil\thistitle}} --\global\oddheadline={\line{\thischapterheading\hfil\folio}} -+\global\oddheadline={\line{\thischapter\hfil\folio}} -+\global\evenchapheadline={\line{\folio\hfil}} -+\global\oddchapheadline={\line{\hfil\folio}} - \global\let\contentsalignmacro = \chapoddpage - } - -@@ -3955,8 +4019,22 @@ - \def\HEADINGSsinglex{% - \global\evenfootline={\hfil} - \global\oddfootline={\hfil} --\global\evenheadline={\line{\thischapterheading\hfil\folio}} --\global\oddheadline={\line{\thischapterheading\hfil\folio}} -+\global\evenheadline={\line{\thischapter\hfil\folio}} -+\global\oddheadline={\line{\thischapter\hfil\folio}} -+\global\evenchapheadline={\line{\hfil\folio}} -+\global\oddchapheadline={\line{\hfil\folio}} -+\global\let\contentsalignmacro = \chappager -+} -+ -+% for @setchapternewpage off -+\def\HEADINGSsinglechapoff{% -+\pageone -+\global\evenfootline={\hfil} -+\global\oddfootline={\hfil} -+\global\evenheadline={\line{\thischapter\hfil\folio}} -+\global\oddheadline={\line{\thischapter\hfil\folio}} -+\global\evenchapheadline=\evenheadline -+\global\oddchapheadline=\oddheadline - \global\let\contentsalignmacro = \chappager - } - -@@ -4389,7 +4467,7 @@ - } - - % multitable-only commands. --% -+% - % @headitem starts a heading row, which we typeset in bold. Assignments - % have to be global since we are inside the implicit group of an - % alignment entry. \everycr below resets \everytab so we don't have to -@@ -4696,19 +4774,6 @@ - } - } - --% We have this subroutine so that we can handle at least some @value's --% properly in indexes (we call \makevalueexpandable in \indexdummies). --% The command has to be fully expandable (if the variable is set), since --% the result winds up in the index file. This means that if the --% variable's value contains other Texinfo commands, it's almost certain --% it will fail (although perhaps we could fix that with sufficient work --% to do a one-level expansion on the result, instead of complete). --% --% Unfortunately, this has the consequence that when _ is in the *value* --% of an @set, it does not print properly in the roman fonts (get the cmr --% dot accent at position 126 instead). No fix comes to mind, and it's --% been this way since 2003 or earlier, so just ignore it. --% - \def\expandablevalue#1{% - \expandafter\ifx\csname SET#1\endcsname\relax - {[No value for ``#1'']}% -@@ -4721,13 +4786,13 @@ - % Like \expandablevalue, but completely expandable (the \message in the - % definition above operates at the execution level of TeX). Used when - % writing to auxiliary files, due to the expansion that \write does. --% If flag is undefined, pass through an unexpanded @value command: maybe it -+% If flag is undefined, pass through an unexpanded @value command: maybe it - % will be set by the time it is read back in. - % - % NB flag names containing - or _ may not work here. - \def\dummyvalue#1{% - \expandafter\ifx\csname SET#1\endcsname\relax -- \noexpand\value{#1}% -+ \string\value{#1}% - \else - \csname SET#1\endcsname - \fi -@@ -4737,7 +4802,7 @@ - % if possible, otherwise sort late. - \def\indexnofontsvalue#1{% - \expandafter\ifx\csname SET#1\endcsname\relax -- ZZZZZZZ -+ ZZZZZZZ% - \else - \csname SET#1\endcsname - \fi -@@ -4745,7 +4810,7 @@ - - % @ifset VAR ... @end ifset reads the `...' iff VAR has been defined - % with @set. --% -+% - % To get the special treatment we need for `@end ifset,' we call - % \makecond and then redefine. - % -@@ -4778,7 +4843,7 @@ - % without the @) is in fact defined. We can only feasibly check at the - % TeX level, so something like `mathcode' is going to considered - % defined even though it is not a Texinfo command. --% -+% - \makecond{ifcommanddefined} - \def\ifcommanddefined{\parsearg{\doifcmddefined{\let\next=\ifcmddefinedfail}}} - % -@@ -4884,32 +4949,18 @@ - - % like the previous two, but they put @code around the argument. - \def\docodeindex#1{\edef\indexname{#1}\parsearg\docodeindexxxx} --\def\docodeindexxxx #1{\doind{\indexname}{\code{#1}}} -+\def\docodeindexxxx #1{\docind{\indexname}{#1}} - -- --% Used when writing an index entry out to an index file to prevent --% expansion of Texinfo commands that can appear in an index entry. --% --\def\indexdummies{% -- \escapechar = `\\ % use backslash in output files. -- \definedummyletter\@% -- \definedummyletter\ % -- % -- % For texindex which always views { and } as separators. -- \def\{{\lbracechar{}}% -- \def\}{\rbracechar{}}% -- % -- % Do the redefinitions. -- \definedummies --} - --% Used for the aux and toc files, where @ is the escape character. -+% Used for the aux, toc and index files to prevent expansion of Texinfo -+% commands. - % - \def\atdummies{% - \definedummyletter\@% - \definedummyletter\ % - \definedummyletter\{% - \definedummyletter\}% -+ \definedummyletter\&% - % - % Do the redefinitions. - \definedummies -@@ -4933,8 +4984,7 @@ - \def\definedummyletter#1{\def#1{\string#1}}% - \let\definedummyaccent\definedummyletter - --% Called from \indexdummies and \atdummies, to effectively prevent --% the expansion of commands. -+% Called from \atdummies to prevent the expansion of commands. - % - \def\definedummies{% - % -@@ -4981,8 +5031,10 @@ - \definedummyword\TeX - % - % Assorted special characters. -+ \definedummyword\ampchar - \definedummyword\atchar - \definedummyword\arrow -+ \definedummyword\backslashchar - \definedummyword\bullet - \definedummyword\comma - \definedummyword\copyright -@@ -5019,6 +5071,8 @@ - \definedummyword\sup - \definedummyword\textdegree - % -+ \definedummyword\subentry -+ % - % We want to disable all macros so that they are not expanded by \write. - \macrolist - \let\value\dummyvalue -@@ -5099,11 +5153,10 @@ - \commondummyword\xref - } - --% For testing: output @{ and @} in index sort strings as \{ and \}. --\newif\ifusebracesinindexes -- - \let\indexlbrace\relax - \let\indexrbrace\relax -+\let\indexatchar\relax -+\let\indexbackslash\relax - - {\catcode`\@=0 - \catcode`\\=13 -@@ -5137,10 +5190,8 @@ - } - - \gdef\indexnonalnumreappear{% -- \useindexbackslash - \let-\normaldash - \let<\normalless -- \def\@{@}% - } - } - -@@ -5174,64 +5225,66 @@ - \let\lbracechar\{% - \let\rbracechar\}% - % -+ % -+ \let\do\indexnofontsdef -+ % - % Non-English letters. -- \def\AA{AA}% -- \def\AE{AE}% -- \def\DH{DZZ}% -- \def\L{L}% -- \def\OE{OE}% -- \def\O{O}% -- \def\TH{TH}% -- \def\aa{aa}% -- \def\ae{ae}% -- \def\dh{dzz}% -- \def\exclamdown{!}% -- \def\l{l}% -- \def\oe{oe}% -- \def\ordf{a}% -- \def\ordm{o}% -- \def\o{o}% -- \def\questiondown{?}% -- \def\ss{ss}% -- \def\th{th}% -- % -- \def\LaTeX{LaTeX}% -- \def\TeX{TeX}% -- % -- % Assorted special characters. \defglyph gives the control sequence a -- % definition that removes the {} that follows its use. -- \defglyph\atchar{@}% -- \defglyph\arrow{->}% -- \defglyph\bullet{bullet}% -- \defglyph\comma{,}% -- \defglyph\copyright{copyright}% -- \defglyph\dots{...}% -- \defglyph\enddots{...}% -- \defglyph\equiv{==}% -- \defglyph\error{error}% -- \defglyph\euro{euro}% -- \defglyph\expansion{==>}% -- \defglyph\geq{>=}% -- \defglyph\guillemetleft{<<}% -- \defglyph\guillemetright{>>}% -- \defglyph\guilsinglleft{<}% -- \defglyph\guilsinglright{>}% -- \defglyph\leq{<=}% -- \defglyph\lbracechar{\{}% -- \defglyph\minus{-}% -- \defglyph\point{.}% -- \defglyph\pounds{pounds}% -- \defglyph\print{-|}% -- \defglyph\quotedblbase{"}% -- \defglyph\quotedblleft{"}% -- \defglyph\quotedblright{"}% -- \defglyph\quoteleft{`}% -- \defglyph\quoteright{'}% -- \defglyph\quotesinglbase{,}% -- \defglyph\rbracechar{\}}% -- \defglyph\registeredsymbol{R}% -- \defglyph\result{=>}% -- \defglyph\textdegree{o}% -+ \do\AA{AA}% -+ \do\AE{AE}% -+ \do\DH{DZZ}% -+ \do\L{L}% -+ \do\OE{OE}% -+ \do\O{O}% -+ \do\TH{TH}% -+ \do\aa{aa}% -+ \do\ae{ae}% -+ \do\dh{dzz}% -+ \do\exclamdown{!}% -+ \do\l{l}% -+ \do\oe{oe}% -+ \do\ordf{a}% -+ \do\ordm{o}% -+ \do\o{o}% -+ \do\questiondown{?}% -+ \do\ss{ss}% -+ \do\th{th}% -+ % -+ \do\LaTeX{LaTeX}% -+ \do\TeX{TeX}% -+ % -+ % Assorted special characters. -+ \do\atchar{@}% -+ \do\arrow{->}% -+ \do\bullet{bullet}% -+ \do\comma{,}% -+ \do\copyright{copyright}% -+ \do\dots{...}% -+ \do\enddots{...}% -+ \do\equiv{==}% -+ \do\error{error}% -+ \do\euro{euro}% -+ \do\expansion{==>}% -+ \do\geq{>=}% -+ \do\guillemetleft{<<}% -+ \do\guillemetright{>>}% -+ \do\guilsinglleft{<}% -+ \do\guilsinglright{>}% -+ \do\leq{<=}% -+ \do\lbracechar{\{}% -+ \do\minus{-}% -+ \do\point{.}% -+ \do\pounds{pounds}% -+ \do\print{-|}% -+ \do\quotedblbase{"}% -+ \do\quotedblleft{"}% -+ \do\quotedblright{"}% -+ \do\quoteleft{`}% -+ \do\quoteright{'}% -+ \do\quotesinglbase{,}% -+ \do\rbracechar{\}}% -+ \do\registeredsymbol{R}% -+ \do\result{=>}% -+ \do\textdegree{o}% - % - % We need to get rid of all macros, leaving only the arguments (if present). - % Of course this is not nearly correct, but it is the best we can do for now. -@@ -5246,41 +5299,38 @@ - \macrolist - \let\value\indexnofontsvalue - } --\def\defglyph#1#2{\def#1##1{#2}} % see above - -- -+% Give the control sequence a definition that removes the {} that follows -+% its use, e.g. @AA{} -> AA -+\def\indexnofontsdef#1#2{\def#1##1{#2}}% - - --\let\SETmarginindex=\relax % put index entries in margin (undocumented)? - --% Most index entries go through here, but \dosubind is the general case. --% #1 is the index name, #2 is the entry text. --\def\doind#1#2{\dosubind{#1}{#2}{}} - --% There is also \dosubind {index}{topic}{subtopic} --% which makes an entry in a two-level index such as the operation index. --% TODO: Two-level index? Operation index? -- --% Workhorse for all indexes. --% #1 is name of index, #2 is stuff to put there, #3 is subentry -- --% empty if called from \doind, as we usually are (the main exception --% is with most defuns, which call us directly). --% --\def\dosubind#1#2#3{% -+% #1 is the index name, #2 is the entry text. -+\def\doind#1#2{% - \iflinks - {% -+ % - \requireopenindexfile{#1}% -- % Store the main index entry text (including the third arg). -- \toks0 = {#2}% -- % If third arg is present, precede it with a space. -- \def\thirdarg{#3}% -- \ifx\thirdarg\empty \else -- \toks0 = \expandafter{\the\toks0 \space #3}% -- \fi -+ \edef\writeto{\csname#1indfile\endcsname}% -+ % -+ \def\indextext{#2}% -+ \safewhatsit\doindwrite -+ }% -+ \fi -+} -+ -+% Same as \doind, but for code indices -+\def\docind#1#2{% -+ \iflinks -+ {% - % -+ \requireopenindexfile{#1}% - \edef\writeto{\csname#1indfile\endcsname}% - % -- \safewhatsit\dosubindwrite -+ \def\indextext{#2}% -+ \safewhatsit\docindwrite - }% - \fi - } -@@ -5295,28 +5345,14 @@ - \ifx\suffix\indexisfl\def\suffix{f1}\fi - % Open the file - \immediate\openout\csname#1indfile\endcsname \jobname.\suffix -- % Using \immediate above here prevents an object entering into the current -+ % Using \immediate above here prevents an object entering into the current - % box, which could confound checks such as those in \safewhatsit for - % preceding skips. - \typeout{Writing index file \jobname.\suffix}% - \fi} - \def\indexisfl{fl} - --% Output \ as {\indexbackslash}, because \ is an escape character in --% the index files. --\let\indexbackslash=\relax --{\catcode`\@=0 \catcode`\\=\active -- @gdef@useindexbackslash{@def\{{@indexbackslash}}} --} -- --% Definition for writing index entry text. --\def\sortas#1{\ignorespaces}% -- --% Definition for writing index entry sort key. Should occur at the at --% the beginning of the index entry, like --% @cindex @sortas{september} \september --% The \ignorespaces takes care of following space, but there's no way --% to remove space before it. -+% Definition for writing index entry sort key. - { - \catcode`\-=13 - \gdef\indexwritesortas{% -@@ -5327,51 +5363,158 @@ - \xdef\indexsortkey{#1}\endgroup} - } - -+\def\indexwriteseealso#1{ -+ \gdef\pagenumbertext{\string\seealso{#1}}% -+} -+\def\indexwriteseeentry#1{ -+ \gdef\pagenumbertext{\string\seeentry{#1}}% -+} -+ -+% The default definitions -+\def\sortas#1{}% -+\def\seealso#1{\i{\putwordSeeAlso}\ #1}% for sorted index file only -+\def\putwordSeeAlso{See also} -+\def\seeentry#1{\i{\putwordSee}\ #1}% for sorted index file only -+ - --% Write the entry in \toks0 to the index file. -+% Given index entry text like "aaa @subentry bbb @sortas{ZZZ}": -+% * Set \bracedtext to "{aaa}{bbb}" -+% * Set \fullindexsortkey to "aaa @subentry ZZZ" -+% * If @seealso occurs, set \pagenumbertext - % --\def\dosubindwrite{% -- % Put the index entry in the margin if desired. -- \ifx\SETmarginindex\relax\else -- \insert\margin{\hbox{\vrule height8pt depth3pt width0pt \the\toks0}}% -+\def\splitindexentry#1{% -+ \gdef\fullindexsortkey{}% -+ \xdef\bracedtext{}% -+ \def\sep{}% -+ \def\seealso##1{}% -+ \def\seeentry##1{}% -+ \expandafter\doindexsegment#1\subentry\finish\subentry -+} -+ -+% append the results from the next segment -+\def\doindexsegment#1\subentry{% -+ \def\segment{#1}% -+ \ifx\segment\isfinish -+ \else -+ % -+ % Fully expand the segment, throwing away any @sortas directives, and -+ % trim spaces. -+ \edef\trimmed{\segment}% -+ \edef\trimmed{\expandafter\eatspaces\expandafter{\trimmed}}% -+ \ifincodeindex -+ \edef\trimmed{\noexpand\code{\trimmed}}% -+ \fi -+ % -+ \xdef\bracedtext{\bracedtext{\trimmed}}% -+ % -+ % Get the string to sort by. Process the segment with all -+ % font commands turned off. -+ \bgroup -+ \let\sortas\indexwritesortas -+ \let\seealso\indexwriteseealso -+ \let\seeentry\indexwriteseeentry -+ \indexnofonts -+ % The braces around the commands are recognized by texindex. -+ \def\lbracechar{{\string\indexlbrace}}% -+ \def\rbracechar{{\string\indexrbrace}}% -+ \let\{=\lbracechar -+ \let\}=\rbracechar -+ \def\@{{\string\indexatchar}}% -+ \def\atchar##1{\@}% -+ \def\backslashchar{{\string\indexbackslash}}% -+ \uccode`\~=`\\ \uppercase{\let~\backslashchar}% -+ % -+ \let\indexsortkey\empty -+ \global\let\pagenumbertext\empty -+ % Execute the segment and throw away the typeset output. This executes -+ % any @sortas or @seealso commands in this segment. -+ \setbox\dummybox = \hbox{\segment}% -+ \ifx\indexsortkey\empty{% -+ \indexnonalnumdisappear -+ \xdef\trimmed{\segment}% -+ \xdef\trimmed{\expandafter\eatspaces\expandafter{\trimmed}}% -+ \xdef\indexsortkey{\trimmed}% -+ \ifx\indexsortkey\empty\xdef\indexsortkey{ }\fi -+ }\fi -+ % -+ % Append to \fullindexsortkey. -+ \edef\tmp{\gdef\noexpand\fullindexsortkey{% -+ \fullindexsortkey\sep\indexsortkey}}% -+ \tmp -+ \egroup -+ \def\sep{\subentry}% -+ % -+ \expandafter\doindexsegment - \fi -+} -+\def\isfinish{\finish}% -+\newbox\dummybox % used above -+ -+\let\subentry\relax -+ -+% Use \ instead of @ in index files. To support old texi2dvi and texindex. -+% This works without changing the escape character used in the toc or aux -+% files because the index entries are fully expanded here, and \string uses -+% the current value of \escapechar. -+\def\escapeisbackslash{\escapechar=`\\} -+ -+% Use \ in index files by default. texi2dvi didn't support @ as the escape -+% character (as it checked for "\entry" in the files, and not "@entry"). When -+% the new version of texi2dvi has had a chance to become more prevalent, then -+% the escape character can change back to @ again. This should be an easy -+% change to make now because both @ and \ are only used as escape characters in -+% index files, never standing for themselves. -+% -+\set txiindexescapeisbackslash -+ -+% Write the entry in \indextext to the index file. -+% -+ -+\newif\ifincodeindex -+\def\doindwrite{\incodeindexfalse\doindwritex} -+\def\docindwrite{\incodeindextrue\doindwritex} -+ -+\def\doindwritex{% -+ \maybemarginindex - % -- % Remember, we are within a group. -- \indexdummies % Must do this here, since \bf, etc expand at this stage -- \useindexbackslash % \indexbackslash isn't defined now so it will be output -- % as is; and it will print as backslash. -- % The braces around \indexbrace are recognized by texindex. -- % -- % Get the string to sort by, by processing the index entry with all -- % font commands turned off. -- {\indexnofonts -- \def\lbracechar{{\indexlbrace}}% -- \def\rbracechar{{\indexrbrace}}% -- \let\{=\lbracechar -- \let\}=\rbracechar -- \indexnonalnumdisappear -- \xdef\indexsortkey{}% -- \let\sortas=\indexwritesortas -- \edef\temp{\the\toks0}% -- \setbox\dummybox = \hbox{\temp}% Make sure to execute any \sortas -- \ifx\indexsortkey\empty -- \xdef\indexsortkey{\temp}% -- \ifx\indexsortkey\empty\xdef\indexsortkey{ }\fi -- \fi -- }% -+ \atdummies -+ % -+ \expandafter\ifx\csname SETtxiindexescapeisbackslash\endcsname\relax\else -+ \escapeisbackslash -+ \fi -+ % -+ % For texindex which always views { and } as separators. -+ \def\{{\lbracechar{}}% -+ \def\}{\rbracechar{}}% -+ \uccode`\~=`\\ \uppercase{\def~{\backslashchar{}}}% -+ % -+ % Split the entry into primary entry and any subentries, and get the index -+ % sort key. -+ \splitindexentry\indextext - % - % Set up the complete index entry, with both the sort key and - % the original text, including any font commands. We write - % three arguments to \entry to the .?? file (four in the - % subentry case), texindex reduces to two when writing the .??s - % sorted result. -+ % - \edef\temp{% - \write\writeto{% -- \string\entry{\indexsortkey}{\noexpand\folio}{\the\toks0}}% -+ \string\entry{\fullindexsortkey}% -+ {\ifx\pagenumbertext\empty\noexpand\folio\else\pagenumbertext\fi}% -+ \bracedtext}% - }% - \temp - } --\newbox\dummybox % used above -+ -+% Put the index entry in the margin if desired (undocumented). -+\def\maybemarginindex{% -+ \ifx\SETmarginindex\relax\else -+ \insert\margin{\hbox{\vrule height8pt depth3pt width0pt \relax\indextext}}% -+ \fi -+} -+\let\SETmarginindex=\relax -+ - - % Take care of unwanted page breaks/skips around a whatsit: - % -@@ -5459,9 +5602,14 @@ - % \entry {topic}{pagelist} - % for a topic that is used without subtopics - % \primary {topic} -+% \entry {topic}{} - % for the beginning of a topic that is used with subtopics - % \secondary {subtopic}{pagelist} - % for each subtopic. -+% \secondary {subtopic}{} -+% for a subtopic with sub-subtopics -+% \tertiary {subtopic}{subsubtopic}{pagelist} -+% for each sub-subtopic. - - % Define the user-accessible indexing commands - % @findex, @vindex, @kindex, @cindex. -@@ -5473,11 +5621,6 @@ - \def\tindex {\tpindex} - \def\pindex {\pgindex} - --\def\cindexsub {\begingroup\obeylines\cindexsub} --{\obeylines % --\gdef\cindexsub "#1" #2^^M{\endgroup % --\dosubind{cp}{#2}{#1}}} -- - % Define the macros used in formatting output of the sorted index material. - - % @printindex causes a particular index (the ??s file) to get printed. -@@ -5491,14 +5634,10 @@ - \plainfrenchspacing - \everypar = {}% don't want the \kern\-parindent from indentation suppression. - % -- % See if the index file exists and is nonempty. -- % Change catcode of @ here so that if the index file contains -- % \initial {@} -- % as its first line, TeX doesn't complain about mismatched braces -- % (because it thinks @} is a control sequence). -- \catcode`\@ = 12 - % See comment in \requireopenindexfile. - \def\indexname{#1}\ifx\indexname\indexisfl\def\indexname{f1}\fi -+ % -+ % See if the index file exists and is nonempty. - \openin 1 \jobname.\indexname s - \ifeof 1 - % \enddoublecolumns gets confused if there is no text in the index, -@@ -5508,8 +5647,6 @@ - \putwordIndexNonexistent - \typeout{No file \jobname.\indexname s.}% - \else -- \catcode`\\ = 0 -- % - % If the index file exists but is empty, then \openin leaves \ifeof - % false. We have to make TeX try to read something from the file, so - % it can discover if there is anything in it. -@@ -5517,47 +5654,55 @@ - \ifeof 1 - \putwordIndexIsEmpty - \else -- % Index files are almost Texinfo source, but we use \ as the escape -- % character. It would be better to use @, but that's too big a change -- % to make right now. -- \def\indexbackslash{\ttbackslash}% -- \let\indexlbrace\{ % Likewise, set these sequences for braces -- \let\indexrbrace\} % used in the sort key. -- \begindoublecolumns -- \let\dotheinsertentrybox\dotheinsertentryboxwithpenalty -- % -- % Read input from the index file line by line. -- \loopdo -- \ifeof1 \else -- \read 1 to \nextline -- \fi -- % -- \indexinputprocessing -- \thisline -- % -- \ifeof1\else -- \let\thisline\nextline -- \repeat -- %% -- \enddoublecolumns -+ \expandafter\printindexzz\thisline\relax\relax\finish% - \fi - \fi - \closein 1 - \endgroup} --\def\loopdo#1\repeat{\def\body{#1}\loopdoxxx} --\def\loopdoxxx{\let\next=\relax\body\let\next=\loopdoxxx\fi\next} - --\def\indexinputprocessing{% -- \ifeof1 -- \let\firsttoken\relax -+% If the index file starts with a backslash, forgo reading the index -+% file altogether. If somebody upgrades texinfo.tex they may still have -+% old index files using \ as the escape character. Reading this would -+% at best lead to typesetting garbage, at worst a TeX syntax error. -+\def\printindexzz#1#2\finish{% -+ \expandafter\ifx\csname SETtxiindexescapeisbackslash\endcsname\relax -+ \uccode`\~=`\\ \uppercase{\if\noexpand~}\noexpand#1 -+ \expandafter\ifx\csname SETtxiskipindexfileswithbackslash\endcsname\relax -+\errmessage{% -+ERROR: A sorted index file in an obsolete format was skipped. -+To fix this problem, please upgrade your version of 'texi2dvi' -+or 'texi2pdf' to that at . -+If you are using an old version of 'texindex' (part of the Texinfo -+distribution), you may also need to upgrade to a newer version (at least 6.0). -+You may be able to typeset the index if you run -+'texindex \jobname.\indexname' yourself. -+You could also try setting the 'txiindexescapeisbackslash' flag by -+running a command like -+'texi2dvi -t "@set txiindexescapeisbackslash" \jobname.texi'. If you do -+this, Texinfo will try to use index files in the old format. -+If you continue to have problems, deleting the index files and starting again -+might help (with 'rm \jobname.?? \jobname.??s')% -+}% -+ \else -+ (Skipped sorted index file in obsolete format) -+ \fi -+ \else -+ \begindoublecolumns -+ \input \jobname.\indexname s -+ \enddoublecolumns -+ \fi - \else -- \edef\act{\gdef\noexpand\firsttoken{\getfirsttoken\nextline}}% -- \act -+ \begindoublecolumns -+ \catcode`\\=0\relax -+ % -+ % Make @ an escape character to give macros a chance to work. This -+ % should work because we (hopefully) don't otherwise use @ in index files. -+ %\catcode`\@=12\relax -+ \catcode`\@=0\relax -+ \input \jobname.\indexname s -+ \enddoublecolumns - \fi - } --\def\getfirsttoken#1{\expandafter\getfirsttokenx#1\endfirsttoken} --\long\def\getfirsttokenx#1#2\endfirsttoken{\noexpand#1} -- - - % These macros are used by the sorted index file itself. - % Change them to control the appearance of the index. -@@ -5566,12 +5711,19 @@ - \catcode`\|=13 \catcode`\<=13 \catcode`\>=13 \catcode`\+=13 \catcode`\"=13 - \catcode`\$=3 - \gdef\initialglyphs{% -+ % special control sequences used in the index sort key -+ \let\indexlbrace\{% -+ \let\indexrbrace\}% -+ \let\indexatchar\@% -+ \def\indexbackslash{\math{\backslash}}% -+ % - % Some changes for non-alphabetic characters. Using the glyphs from the - % math fonts looks more consistent than the typewriter font used elsewhere - % for these characters. -- \def\indexbackslash{\math{\backslash}}% -- \let\\=\indexbackslash -+ \uccode`\~=`\\ \uppercase{\def~{\math{\backslash}}} - % -+ % In case @\ is used for backslash -+ \uppercase{\let\\=~} - % Can't get bold backslash so don't use bold forward slash - \catcode`\/=13 - \def/{{\secrmnotbold \normalslash}}% -@@ -5601,7 +5753,7 @@ - % bottom of a column to reduce an increase in inter-line spacing. - \nobreak - \vskip 0pt plus 5\baselineskip -- \penalty -300 -+ \penalty -300 - \vskip 0pt plus -5\baselineskip - % - % Typeset the initial. Making this add up to a whole number of -@@ -5631,12 +5783,6 @@ - \def\entry{% - \begingroup - % -- % For pdfTeX and XeTeX. -- % The redefinition of \domark stops marks being added in \pdflink to -- % preserve coloured links across page boundaries. Otherwise the marks -- % would get in the way of \lastbox in \insertentrybox. -- \let\domark\relax -- % - % Start a new paragraph if necessary, so our assignments below can't - % affect previous text. - \par -@@ -5669,35 +5815,31 @@ - \gdef\finishentry#1{% - \egroup % end box A - \dimen@ = \wd\boxA % Length of text of entry -- \global\setbox\boxA=\hbox\bgroup\unhbox\boxA -- % #1 is the page number. -- % -- % Get the width of the page numbers, and only use -- % leaders if they are present. -- \global\setbox\boxB = \hbox{#1}% -- \ifdim\wd\boxB = 0pt -- \null\nobreak\hfill\ % -- \else -- % -- \null\nobreak\indexdotfill % Have leaders before the page number. -+ \global\setbox\boxA=\hbox\bgroup -+ \unhbox\boxA -+ % #1 is the page number. - % -- \ifpdf -- \pdfgettoks#1.% -- \hskip\skip\thinshrinkable\the\toksA -+ % Get the width of the page numbers, and only use -+ % leaders if they are present. -+ \global\setbox\boxB = \hbox{#1}% -+ \ifdim\wd\boxB = 0pt -+ \null\nobreak\hfill\ % - \else -- \ifx\XeTeXrevision\thisisundefined -- \hskip\skip\thinshrinkable #1% -- \else -+ % -+ \null\nobreak\indexdotfill % Have leaders before the page number. -+ % -+ \ifpdforxetex - \pdfgettoks#1.% - \hskip\skip\thinshrinkable\the\toksA -+ \else -+ \hskip\skip\thinshrinkable #1% - \fi - \fi -- \fi - \egroup % end \boxA - \ifdim\wd\boxB = 0pt -- \global\setbox\entrybox=\vbox{\unhbox\boxA}% -- \else -- \global\setbox\entrybox=\vbox\bgroup -+ \noindent\unhbox\boxA\par -+ \nobreak -+ \else\bgroup - % We want the text of the entries to be aligned to the left, and the - % page numbers to be aligned to the right. - % -@@ -5727,7 +5869,7 @@ - \advance\dimen@ii by 1\dimen@i - \ifdim\wd\boxA > \dimen@ii % If the entry doesn't fit in one line - \ifdim\dimen@ > 0.8\dimen@ii % due to long index text -- % Try to split the text roughly evenly. \dimen@ will be the length of -+ % Try to split the text roughly evenly. \dimen@ will be the length of - % the first line. - \dimen@ = 0.7\dimen@ - \dimen@ii = \hsize -@@ -5763,55 +5905,11 @@ - \egroup % The \vbox - \fi - \endgroup -- \dotheinsertentrybox - }} - - \newskip\thinshrinkable - \skip\thinshrinkable=.15em minus .15em - --\newbox\entrybox --\def\insertentrybox{% -- \ourunvbox\entrybox --} -- --% default definition --\let\dotheinsertentrybox\insertentrybox -- --% Use \lastbox to take apart vbox box by box, and add each sub-box --% to the current vertical list. --\def\ourunvbox#1{% --\bgroup % for local binding of \delayedbox -- % Remove the last box from box #1 -- \global\setbox#1=\vbox{% -- \unvbox#1% -- \unskip % remove any glue -- \unpenalty -- \global\setbox\interbox=\lastbox -- }% -- \setbox\delayedbox=\box\interbox -- \ifdim\ht#1=0pt\else -- \ourunvbox#1 % Repeat on what's left of the box -- \nobreak -- \fi -- \box\delayedbox --\egroup --} --\newbox\delayedbox --\newbox\interbox -- --% Used from \printindex. \firsttoken should be the first token --% after the \entry. If it's not another \entry, we are at the last --% line of a group of index entries, so insert a penalty to discourage --% widowed index entries. --\def\dotheinsertentryboxwithpenalty{% -- \ifx\firsttoken\isentry -- \else -- \penalty 9000 -- \fi -- \insertentrybox --} --\def\isentry{\entry}% -- - % Like plain.tex's \dotfill, except uses up at least 1 em. - % The filll stretch here overpowers both the fil and fill stretch to push - % the page number to the right. -@@ -5821,24 +5919,15 @@ - - \def\primary #1{\line{#1\hfil}} - --\newskip\secondaryindent \secondaryindent=0.5cm --\def\secondary#1#2{{% -- \parfillskip=0in -- \parskip=0in -- \hangindent=1in -- \hangafter=1 -- \noindent\hskip\secondaryindent\hbox{#1}\indexdotfill -- \ifpdf -- \pdfgettoks#2.\ \the\toksA % The page number ends the paragraph. -- \else -- \ifx\XeTeXrevision\thisisundefined -- #2 -- \else -- \pdfgettoks#2.\ \the\toksA % The page number ends the paragraph. -- \fi -- \fi -- \par --}} -+\def\secondary{\indententry{0.5cm}} -+\def\tertiary{\indententry{1cm}} -+ -+\def\indententry#1#2#3{% -+ \bgroup -+ \leftskip=#1 -+ \entry{#2}{#3}% -+ \egroup -+} - - % Define two-column mode, which we use to typeset indexes. - % Adapted from the TeXbook, page 416, which is to say, -@@ -5848,60 +5937,21 @@ - \newbox\partialpage - \newdimen\doublecolumnhsize - --% Use inside an output routine to save \topmark and \firstmark --\def\savemarks{% -- \global\savedtopmark=\expandafter{\topmark }% -- \global\savedfirstmark=\expandafter{\firstmark }% --} --\newtoks\savedtopmark --\newtoks\savedfirstmark -- --% Set \topmark and \firstmark for next time \output runs. --% Can't be run from withinside \output (because any material --% added while an output routine is active, including --% penalties, is saved for after it finishes). The page so far --% should be empty, otherwise what's on it will be thrown away. --\def\restoremarks{% -- \mark{\the\savedtopmark}% -- \bgroup\output = {% -- \setbox\dummybox=\box\PAGE -- }abc\eject\egroup -- % "abc" because output routine doesn't fire for a completely empty page. -- \mark{\the\savedfirstmark}% --} -- - \def\begindoublecolumns{\begingroup % ended by \enddoublecolumns - % If not much space left on page, start a new page. - \ifdim\pagetotal>0.8\vsize\vfill\eject\fi - % - % Grab any single-column material above us. - \output = {% -- % -- % Here is a possibility not foreseen in manmac: if we accumulate a -- % whole lot of material, we might end up calling this \output -- % routine twice in a row (see the doublecol-lose test, which is -- % essentially a couple of indexes with @setchapternewpage off). In -- % that case we just ship out what is in \partialpage with the normal -- % output routine. Generally, \partialpage will be empty when this -- % runs and this will be a no-op. See the indexspread.tex test case. -- \ifvoid\partialpage \else -- \onepageout{\pagecontents\partialpage}% -- \fi -+ \savetopmark - % - \global\setbox\partialpage = \vbox{% - % Unvbox the main output page. - \unvbox\PAGE - \kern-\topskip \kern\baselineskip - }% -- \savemarks - }% - \eject % run that output routine to set \partialpage -- \restoremarks -- % -- % We recover the two marks that the last output routine saved in order -- % to propagate the information in marks added around a chapter heading, -- % which could be otherwise be lost by the time the final page is output. -- % - % - % Use the double-column output routine for subsequent pages. - \output = {\doublecolumnout}% -@@ -5927,7 +5977,9 @@ - \divide\doublecolumnhsize by 2 - \hsize = \doublecolumnhsize - % -- % Double the \vsize as well. -+ % Get the available space for the double columns -- the normal -+ % (undoubled) page height minus any material left over from the -+ % previous page. - \advance\vsize by -\ht\partialpage - \vsize = 2\vsize - % -@@ -5940,17 +5992,15 @@ - % - \def\doublecolumnout{% - % -+ \savetopmark - \splittopskip=\topskip \splitmaxdepth=\maxdepth -- % Get the available space for the double columns -- the normal -- % (undoubled) page height minus any material left over from the -- % previous page. - \dimen@ = \vsize - \divide\dimen@ by 2 - % - % box0 will be the left-hand column, box2 the right. - \setbox0=\vsplit\PAGE to\dimen@ \setbox2=\vsplit\PAGE to\dimen@ - \global\advance\vsize by 2\ht\partialpage -- \onepageout\pagesofar -+ \onepageout\pagesofar % empty except for the first time we are called - \unvbox\PAGE - \penalty\outputpenalty - } -@@ -5966,7 +6016,7 @@ - } - - --% Finished with with double columns. -+% Finished with double columns. - \def\enddoublecolumns{% - % The following penalty ensures that the page builder is exercised - % _before_ we change the output routine. This is necessary in the -@@ -5998,7 +6048,7 @@ - % - \output = {% - % Split the last of the double-column material. -- \savemarks -+ \savetopmark - \balancecolumns - }% - \eject % call the \output just set -@@ -6006,10 +6056,9 @@ - % Having called \balancecolumns once, we do not - % want to call it again. Therefore, reset \output to its normal - % definition right away. -- \global\output = {\onepageout{\pagecontents\PAGE}}% -+ \global\output=\expandafter{\the\defaultoutput} - % - \endgroup % started in \begindoublecolumns -- \restoremarks - % Leave the double-column material on the current page, no automatic - % page break. - \box\balancedcolumns -@@ -6028,18 +6077,19 @@ - \newbox\balancedcolumns - \setbox\balancedcolumns=\vbox{shouldnt see this}% - % --% Only called for the last of the double column material. \doublecolumnout -+% Only called for the last of the double column material. \doublecolumnout - % does the others. - \def\balancecolumns{% - \setbox0 = \vbox{\unvbox\PAGE}% like \box255 but more efficient, see p.120. - \dimen@ = \ht0 -- \advance\dimen@ by \topskip -- \advance\dimen@ by-\baselineskip -- \ifdim\dimen@<5\baselineskip -+ \ifdim\dimen@<7\baselineskip - % Don't split a short final column in two. - \setbox2=\vbox{}% - \global\setbox\balancedcolumns=\vbox{\pagesofar}% - \else -+ % double the leading vertical space -+ \advance\dimen@ by \topskip -+ \advance\dimen@ by-\baselineskip - \divide\dimen@ by 2 % target to split to - \dimen@ii = \dimen@ - \splittopskip = \topskip -@@ -6055,7 +6105,7 @@ - }% - % Now the left column is in box 1, and the right column in box 3. - % -- % Check whether the left column has come out higher than the page itself. -+ % Check whether the left column has come out higher than the page itself. - % (Note that we have doubled \vsize for the double columns, so - % the actual height of the page is 0.5\vsize). - \ifdim2\ht1>\vsize -@@ -6174,11 +6224,9 @@ - - % @raisesections: treat @section as chapter, @subsection as section, etc. - \def\raisesections{\global\advance\secbase by -1} --\let\up=\raisesections % original BFox name - - % @lowersections: treat @chapter as section, @section as subsection, etc. - \def\lowersections{\global\advance\secbase by 1} --\let\down=\lowersections % original BFox name - - % we only have subsub. - \chardef\maxseclevel = 3 -@@ -6354,7 +6402,7 @@ - \let\top\unnumbered - - % Sections. --% -+% - \outer\parseargdef\numberedsec{\numhead1{#1}} % normally calls seczzz - \def\seczzz#1{% - \global\subsecno=0 \global\subsubsecno=0 \global\advance\secno by 1 -@@ -6377,7 +6425,7 @@ - } - - % Subsections. --% -+% - % normally calls numberedsubseczzz: - \outer\parseargdef\numberedsubsec{\numhead2{#1}} - \def\numberedsubseczzz#1{% -@@ -6402,7 +6450,7 @@ - } - - % Subsubsections. --% -+% - % normally numberedsubsubseczzz: - \outer\parseargdef\numberedsubsubsec{\numhead3{#1}} - \def\numberedsubsubseczzz#1{% -@@ -6492,18 +6540,16 @@ - \def\CHAPPAGoff{% - \global\let\contentsalignmacro = \chappager - \global\let\pchapsepmacro=\chapbreak --\global\let\pagealignmacro=\chappager} -+\global\def\HEADINGSon{\HEADINGSsinglechapoff}} - - \def\CHAPPAGon{% - \global\let\contentsalignmacro = \chappager - \global\let\pchapsepmacro=\chappager --\global\let\pagealignmacro=\chappager - \global\def\HEADINGSon{\HEADINGSsingle}} - - \def\CHAPPAGodd{% - \global\let\contentsalignmacro = \chapoddpage - \global\let\pchapsepmacro=\chapoddpage --\global\let\pagealignmacro=\chapoddpage - \global\def\HEADINGSon{\HEADINGSdouble}} - - \CHAPPAGon -@@ -6523,27 +6569,22 @@ - \expandafter\ifx\thisenv\titlepage\else - \checkenv{}% chapters, etc., should not start inside an environment. - \fi -- % FIXME: \chapmacro is currently called from inside \titlepage when -- % \setcontentsaftertitlepage to print the "Table of Contents" heading, but -- % this should probably be done by \sectionheading with an option to print -- % in chapter size. -- % - % Insert the first mark before the heading break (see notes for \domark). -- \let\prevchapterdefs=\lastchapterdefs -- \let\prevsectiondefs=\lastsectiondefs -- \gdef\lastsectiondefs{\gdef\thissectionname{}\gdef\thissectionnum{}% -+ \let\prevchapterdefs=\currentchapterdefs -+ \let\prevsectiondefs=\currentsectiondefs -+ \gdef\currentsectiondefs{\gdef\thissectionname{}\gdef\thissectionnum{}% - \gdef\thissection{}}% - % - \def\temptype{#2}% - \ifx\temptype\Ynothingkeyword -- \gdef\lastchapterdefs{\gdef\thischaptername{#1}\gdef\thischapternum{}% -+ \gdef\currentchapterdefs{\gdef\thischaptername{#1}\gdef\thischapternum{}% - \gdef\thischapter{\thischaptername}}% - \else\ifx\temptype\Yomitfromtockeyword -- \gdef\lastchapterdefs{\gdef\thischaptername{#1}\gdef\thischapternum{}% -+ \gdef\currentchapterdefs{\gdef\thischaptername{#1}\gdef\thischapternum{}% - \gdef\thischapter{}}% - \else\ifx\temptype\Yappendixkeyword - \toks0={#1}% -- \xdef\lastchapterdefs{% -+ \xdef\currentchapterdefs{% - \gdef\noexpand\thischaptername{\the\toks0}% - \gdef\noexpand\thischapternum{\appendixletter}% - % \noexpand\putwordAppendix avoids expanding indigestible -@@ -6554,7 +6595,7 @@ - }% - \else - \toks0={#1}% -- \xdef\lastchapterdefs{% -+ \xdef\currentchapterdefs{% - \gdef\noexpand\thischaptername{\the\toks0}% - \gdef\noexpand\thischapternum{\the\chapno}% - % \noexpand\putwordChapter avoids expanding indigestible -@@ -6574,18 +6615,18 @@ - % - % Now the second mark, after the heading break. No break points - % between here and the heading. -- \let\prevchapterdefs=\lastchapterdefs -- \let\prevsectiondefs=\lastsectiondefs -+ \let\prevchapterdefs=\currentchapterdefs -+ \let\prevsectiondefs=\currentsectiondefs - \domark - % - {% - \chapfonts \rm - \let\footnote=\errfootnoteheading % give better error message - % -- % Have to define \lastsection before calling \donoderef, because the -+ % Have to define \currentsection before calling \donoderef, because the - % xref code eventually uses it. On the other hand, it has to be called - % after \pchapsepmacro, or the headline will change too soon. -- \gdef\lastsection{#1}% -+ \gdef\currentsection{#1}% - % - % Only insert the separating space if we have a chapter/appendix - % number, and don't print the unnumbered ``number''. -@@ -6674,10 +6715,10 @@ - \csname #2fonts\endcsname \rm - % - % Insert first mark before the heading break (see notes for \domark). -- \let\prevsectiondefs=\lastsectiondefs -+ \let\prevsectiondefs=\currentsectiondefs - \ifx\temptype\Ynothingkeyword - \ifx\sectionlevel\seckeyword -- \gdef\lastsectiondefs{\gdef\thissectionname{#1}\gdef\thissectionnum{}% -+ \gdef\currentsectiondefs{\gdef\thissectionname{#1}\gdef\thissectionnum{}% - \gdef\thissection{\thissectionname}}% - \fi - \else\ifx\temptype\Yomitfromtockeyword -@@ -6685,7 +6726,7 @@ - \else\ifx\temptype\Yappendixkeyword - \ifx\sectionlevel\seckeyword - \toks0={#1}% -- \xdef\lastsectiondefs{% -+ \xdef\currentsectiondefs{% - \gdef\noexpand\thissectionname{\the\toks0}% - \gdef\noexpand\thissectionnum{#4}% - % \noexpand\putwordSection avoids expanding indigestible -@@ -6698,7 +6739,7 @@ - \else - \ifx\sectionlevel\seckeyword - \toks0={#1}% -- \xdef\lastsectiondefs{% -+ \xdef\currentsectiondefs{% - \gdef\noexpand\thissectionname{\the\toks0}% - \gdef\noexpand\thissectionnum{#4}% - % \noexpand\putwordSection avoids expanding indigestible -@@ -6724,28 +6765,28 @@ - % - % Now the second mark, after the heading break. No break points - % between here and the heading. -- \global\let\prevsectiondefs=\lastsectiondefs -+ \global\let\prevsectiondefs=\currentsectiondefs - \domark - % - % Only insert the space after the number if we have a section number. - \ifx\temptype\Ynothingkeyword - \setbox0 = \hbox{}% - \def\toctype{unn}% -- \gdef\lastsection{#1}% -+ \gdef\currentsection{#1}% - \else\ifx\temptype\Yomitfromtockeyword - % for @headings -- no section number, don't include in toc, -- % and don't redefine \lastsection. -+ % and don't redefine \currentsection. - \setbox0 = \hbox{}% - \def\toctype{omit}% - \let\sectionlevel=\empty - \else\ifx\temptype\Yappendixkeyword - \setbox0 = \hbox{#4\enspace}% - \def\toctype{app}% -- \gdef\lastsection{#1}% -+ \gdef\currentsection{#1}% - \else - \setbox0 = \hbox{#4\enspace}% - \def\toctype{num}% -- \gdef\lastsection{#1}% -+ \gdef\currentsection{#1}% - \fi\fi\fi - % - % Write the toc entry (before \donoderef). See comments in \chapmacro. -@@ -6835,13 +6876,8 @@ - % 1 and 2 (the page numbers aren't printed), and so are the first - % two pages of the document. Thus, we'd have two destinations named - % `1', and two named `2'. -- \ifpdf -+ \ifpdforxetex - \global\pdfmakepagedesttrue -- \else -- \ifx\XeTeXrevision\thisisundefined -- \else -- \global\pdfmakepagedesttrue -- \fi - \fi - } - -@@ -6878,9 +6914,7 @@ - % - \def\startcontents#1{% - % If @setchapternewpage on, and @headings double, the contents should -- % start on an odd page, unlike chapters. Thus, we maintain -- % \contentsalignmacro in parallel with \pagealignmacro. -- % From: Torbjorn Granlund -+ % start on an odd page, unlike chapters. - \contentsalignmacro - \immediate\closeout\tocfile - % -@@ -6895,6 +6929,9 @@ - % - % Roman numerals for page numbers. - \ifnum \pageno>0 \global\pageno = \lastnegativepageno \fi -+ \def\thistitle{}% no title in double-sided headings -+ % Record where the Roman numerals started. -+ \ifnum\romancount=0 \global\romancount=\pagecount \fi - } - - % redefined for the two-volume lispref. We always output on -@@ -6917,8 +6954,7 @@ - \fi - \closein 1 - \endgroup -- \lastnegativepageno = \pageno -- \global\pageno = \savepageno -+ \contentsendroman - } - - % And just the chapters. -@@ -6953,10 +6989,20 @@ - \vfill \eject - \contentsalignmacro % in case @setchapternewpage odd is in effect - \endgroup -+ \contentsendroman -+} -+\let\shortcontents = \summarycontents -+ -+% Get ready to use Arabic numerals again -+\def\contentsendroman{% - \lastnegativepageno = \pageno - \global\pageno = \savepageno -+ % -+ % If \romancount > \arabiccount, the contents are at the end of the -+ % document. Otherwise, advance where the Arabic numerals start for -+ % the page numbers. -+ \ifnum\romancount>\arabiccount\else\global\arabiccount=\pagecount\fi - } --\let\shortcontents = \summarycontents - - % Typeset the label for a chapter or appendix for the short contents. - % The arg is, e.g., `A' for an appendix, or `3' for a chapter. -@@ -7204,11 +7250,7 @@ - - % @cartouche ... @end cartouche: draw rectangle w/rounded corners around - % environment contents. --\font\circle=lcircle10 --\newdimen\circthick --\newdimen\cartouter\newdimen\cartinner --\newskip\normbskip\newskip\normpskip\newskip\normlskip --\circthick=\fontdimen8\circle -+ - % - \def\ctl{{\circle\char'013\hskip -6pt}}% 6pt from pl file: 1/2charwidth - \def\ctr{{\hskip 6pt\circle\char'010}} -@@ -7223,7 +7265,18 @@ - % - \newskip\lskip\newskip\rskip - -+% only require the font if @cartouche is actually used -+\def\cartouchefontdefs{% -+ \font\circle=lcircle10\relax -+ \circthick=\fontdimen8\circle -+} -+\newdimen\circthick -+\newdimen\cartouter\newdimen\cartinner -+\newskip\normbskip\newskip\normpskip\newskip\normlskip -+ -+ - \envdef\cartouche{% -+ \cartouchefontdefs - \ifhmode\par\fi % can't be in the midst of a paragraph. - \startsavinginserts - \lskip=\leftskip \rskip=\rightskip -@@ -7402,13 +7455,9 @@ - - - % @raggedright does more-or-less normal line breaking but no right --% justification. From plain.tex. Don't stretch around special --% characters in urls in this environment, since the stretch at the right --% should be enough. -+% justification. From plain.tex. - \envdef\raggedright{% - \rightskip0pt plus2.4em \spaceskip.3333em \xspaceskip.5em\relax -- \def\urefprestretchamount{0pt}% -- \def\urefpoststretchamount{0pt}% - } - \let\Eraggedright\par - -@@ -7467,7 +7516,7 @@ - - % @indentedblock is like @quotation, but indents only on the left and - % has no optional argument. --% -+% - \makedispenvdef{indentedblock}{\indentedblockstart} - % - \def\indentedblockstart{% -@@ -7542,13 +7591,9 @@ - \newdimen\tabw \setbox0=\hbox{\tt\space} \tabw=8\wd0 % tab amount - % - % We typeset each line of the verbatim in an \hbox, so we can handle --% tabs. The \global is in case the verbatim line starts with an accent, --% or some other command that starts with a begin-group. Otherwise, the --% entire \verbbox would disappear at the corresponding end-group, before --% it is typeset. Meanwhile, we can't have nested verbatim commands --% (can we?), so the \global won't be overwriting itself. -+% tabs. - \newbox\verbbox --\def\starttabbox{\global\setbox\verbbox=\hbox\bgroup} -+\def\starttabbox{\setbox\verbbox=\hbox\bgroup} - % - \begingroup - \catcode`\^^I=\active -@@ -7559,7 +7604,8 @@ - \divide\dimen\verbbox by\tabw - \multiply\dimen\verbbox by\tabw % compute previous multiple of \tabw - \advance\dimen\verbbox by\tabw % advance to next multiple of \tabw -- \wd\verbbox=\dimen\verbbox \box\verbbox \starttabbox -+ \wd\verbbox=\dimen\verbbox -+ \leavevmode\box\verbbox \starttabbox - }% - } - \endgroup -@@ -7569,9 +7615,7 @@ - \let\nonarrowing = t% - \nonfillstart - \tt % easiest (and conventionally used) font for verbatim -- % The \leavevmode here is for blank lines. Otherwise, we would -- % never \starttabox and the \egroup would end verbatim mode. -- \def\par{\leavevmode\egroup\box\verbbox\endgraf}% -+ \def\par{\egroup\leavevmode\box\verbbox\endgraf\starttabbox}% - \tabexpand - \setupmarkupstyle{verbatim}% - % Respect line breaks, -@@ -7579,7 +7623,6 @@ - % make each space count. - % Must do in this order: - \obeylines \uncatcodespecials \sepspaces -- \everypar{\starttabbox}% - } - - % Do the @verb magic: verbatim text is quoted by unique -@@ -7614,13 +7657,16 @@ - % ignore everything up to the first ^^M, that's the newline at the end - % of the @verbatim input line itself. Otherwise we get an extra blank - % line in the output. -- \xdef\doverbatim#1^^M#2@end verbatim{#2\noexpand\end\gobble verbatim}% -+ \xdef\doverbatim#1^^M#2@end verbatim{% -+ \starttabbox#2\egroup\noexpand\end\gobble verbatim}% - % We really want {...\end verbatim} in the body of the macro, but - % without the active space; thus we have to use \xdef and \gobble. -+ % The \egroup ends the \verbbox started at the end of the last line in -+ % the block. - \endgroup - % - \envdef\verbatim{% -- \setupverbatim\doverbatim -+ \setnormaldispenv\setupverbatim\doverbatim - } - \let\Everbatim = \afterenvbreak - -@@ -7633,9 +7679,12 @@ - {% - \makevalueexpandable - \setupverbatim -- \indexnofonts % Allow `@@' and other weird things in file names. -- \wlog{texinfo.tex: doing @verbatiminclude of #1^^J}% -- \input #1 -+ {% -+ \indexnofonts % Allow `@@' and other weird things in file names. -+ \wlog{texinfo.tex: doing @verbatiminclude of #1^^J}% -+ \edef\tmp{\noexpand\input #1 } -+ \expandafter -+ }\expandafter\starttabbox\tmp\egroup - \afterenvbreak - }% - } -@@ -7764,7 +7813,7 @@ - % @deftypefnnewline on|off says whether the return type of typed functions - % are printed on their own line. This affects @deftypefn, @deftypefun, - % @deftypeop, and @deftypemethod. --% -+% - \parseargdef\deftypefnnewline{% - \def\temp{#1}% - \ifx\temp\onword -@@ -7780,6 +7829,21 @@ - \fi\fi - } - -+% \dosubind {index}{topic}{subtopic} -+% -+% If SUBTOPIC is present, precede it with a space, and call \doind. -+% (At some time during the 20th century, this made a two-level entry in an -+% index such as the operation index. Nobody seemed to notice the change in -+% behaviour though.) -+\def\dosubind#1#2#3{% -+ \def\thirdarg{#3}% -+ \ifx\thirdarg\empty -+ \doind{#1}{#2}% -+ \else -+ \doind{#1}{#2\space#3}% -+ \fi -+} -+ - % Untyped functions: - - % @deffn category name args -@@ -7794,7 +7858,6 @@ - % \deffngeneral {subind}category name args - % - \def\deffngeneral#1#2 #3 #4\endheader{% -- % Remember that \dosubind{fn}{foo}{} is equivalent to \doind{fn}{foo}. - \dosubind{fn}{\code{#3}}{#1}% - \defname{#2}{}{#3}\magicamp\defunargs{#4\unskip}% - } -@@ -7945,7 +8008,7 @@ - \tclose{\temp}% typeset the return type - \ifrettypeownline - % put return type on its own line; prohibit line break following: -- \hfil\vadjust{\nobreak}\break -+ \hfil\vadjust{\nobreak}\break - \else - \space % type on same line, so just followed by a space - \fi -@@ -8001,6 +8064,7 @@ - \gdef\boldbrax{\let(=\opnr\let)=\clnr\let[=\lbrb\let]=\rbrb} - \gdef\magicamp{\let&=\amprm} - } -+\let\ampchar\& - - \newcount\parencount - -@@ -8081,36 +8145,18 @@ - } - \fi - --% alias because \c means cedilla in @tex or @math --\let\texinfoc=\c -- --\newcount\savedcatcodeone --\newcount\savedcatcodetwo -- - % Used at the time of macro expansion. - % Argument is macro body with arguments substituted - \def\scanmacro#1{% - \newlinechar`\^^M - \def\xeatspaces{\eatspaces}% - % -- % Temporarily undo catcode changes of \printindex. Set catcode of @ to -- % 0 so that @-commands in macro expansions aren't printed literally when -- % formatting an index file, where \ is used as the escape character. -- \savedcatcodeone=\catcode`\@ -- \savedcatcodetwo=\catcode`\\ -- \catcode`\@=0 -- \catcode`\\=\active -- % - % Process the macro body under the current catcode regime. -- \scantokens{#1@texinfoc}% -+ \scantokens{#1@comment}% - % -- \catcode`\@=\savedcatcodeone -- \catcode`\\=\savedcatcodetwo -- % -- % The \texinfoc is to remove the \newlinechar added by \scantokens, and -- % can be noticed by \parsearg. -- % We avoid surrounding the call to \scantokens with \bgroup and \egroup -- % to allow macros to open or close groups themselves. -+ % The \comment is to remove the \newlinechar added by \scantokens, and -+ % can be noticed by \parsearg. Note \c isn't used because this means cedilla -+ % in math mode. - } - - % Used for copying and captions -@@ -8211,12 +8257,14 @@ - \def\macroargctxt{% - \scanctxt - \catcode`\ =\active -+ \catcode`\@=\other - \catcode`\^^M=\other - \catcode`\\=\active - } - - \def\macrolineargctxt{% used for whole-line arguments without braces - \scanctxt -+ \catcode`\@=\other - \catcode`\{=\other - \catcode`\}=\other - } -@@ -8308,7 +8356,7 @@ - % list to some hook where the argument is to be expanded. If there are - % less than 10 arguments that hook is to be replaced by ##N where N - % is the position in that list, that is to say the macro arguments are to be --% defined `a la TeX in the macro body. -+% defined `a la TeX in the macro body. - % - % That gets used by \mbodybackslash (above). - % -@@ -8339,8 +8387,8 @@ - % - % Read recursive and nonrecursive macro bodies. (They're different since - % rec and nonrec macros end differently.) --% --% We are in \macrobodyctxt, and the \xdef causes backslashshes in the macro -+% -+% We are in \macrobodyctxt, and the \xdef causes backslashshes in the macro - % body to be transformed. - % Set \macrobody to the body of the macro, and call \defmacro. - % -@@ -8374,7 +8422,7 @@ - % twice the \macarg.BLAH macros does not cost too much processing power. - \def\parsemmanyargdef@@#1,{% - \if#1;\let\next=\relax -- \else -+ \else - \let\next=\parsemmanyargdef@@ - \edef\tempb{\eatspaces{#1}}% - \expandafter\def\expandafter\tempa -@@ -8459,7 +8507,7 @@ - - % Replace arguments by their values in the macro body, and place the result - % in macro \@tempa. --% -+% - \def\macvalstoargs@{% - % To do this we use the property that token registers that are \the'ed - % within an \edef expand only once. So we are going to place all argument -@@ -8483,9 +8531,9 @@ - \expandafter\def\expandafter\@tempa\expandafter{\@tempc}% - } - --% Define the named-macro outside of this group and then close this group. --% --\def\macargexpandinbody@{% -+% Define the named-macro outside of this group and then close this group. -+% -+\def\macargexpandinbody@{% - \expandafter - \endgroup - \macargdeflist@ -@@ -8523,7 +8571,7 @@ - } - - % Trailing missing arguments are set to empty. --% -+% - \def\setemptyargvalues@{% - \ifx\paramlist\nilm@ - \let\next\macargexpandinbody@ -@@ -8600,7 +8648,7 @@ - \else % at most 9 - \ifnum\paramno<10\relax - % @MACNAME sets the context for reading the macro argument -- % @MACNAME@@ gets the argument, processes backslashes and appends a -+ % @MACNAME@@ gets the argument, processes backslashes and appends a - % comma. - % @MACNAME@@@ removes braces surrounding the argument list. - % @MACNAME@@@@ scans the macro body with arguments substituted. -@@ -8644,11 +8692,11 @@ - % Call #1 with a list of tokens #2, with any doubled backslashes in #2 - % compressed to one. - % --% This implementation works by expansion, and not execution (so we cannot use --% \def or similar). This reduces the risk of this failing in contexts where --% complete expansion is done with no execution (for example, in writing out to -+% This implementation works by expansion, and not execution (so we cannot use -+% \def or similar). This reduces the risk of this failing in contexts where -+% complete expansion is done with no execution (for example, in writing out to - % an auxiliary file for an index entry). --% -+% - % State is kept in the input stream: the argument passed to - % @look_ahead, @gobble_and_check_finish and @add_segment is - % -@@ -8670,11 +8718,11 @@ - % #3 - NEXT_TOKEN - % #4 used to look ahead - % --% If the next token is not a backslash, process the rest of the argument; -+% If the next token is not a backslash, process the rest of the argument; - % otherwise, remove the next token. - @gdef@look_ahead#1!#2#3#4{% - @ifx#4\% -- @expandafter@gobble_and_check_finish -+ @expandafter@gobble_and_check_finish - @else - @expandafter@add_segment - @fi#1!{#2}#4#4% -@@ -8698,9 +8746,9 @@ - % #3 - NEXT_TOKEN - % #4 is input stream until next backslash - % --% Input stream is either at the start of the argument, or just after a --% backslash sequence, either a lone backslash, or a doubled backslash. --% NEXT_TOKEN contains the first token in the input stream: if it is \finish, -+% Input stream is either at the start of the argument, or just after a -+% backslash sequence, either a lone backslash, or a doubled backslash. -+% NEXT_TOKEN contains the first token in the input stream: if it is \finish, - % finish; otherwise, append to ARG_RESULT the segment of the argument up until - % the next backslash. PENDING_BACKSLASH contains a backslash to represent - % a backslash just before the start of the input stream that has not been -@@ -8712,13 +8760,13 @@ - % append the pending backslash to the result, followed by the next segment - @expandafter@is_fi@look_ahead#1#2#4!{\}@fi - % this @fi is discarded by @look_ahead. -- % we can't get rid of it with \expandafter because we don't know how -+ % we can't get rid of it with \expandafter because we don't know how - % long #4 is. - } - - % #1 - THE_MACRO - % #2 - ARG_RESULT --% #3 discards the res of the conditional in @add_segment, and @is_fi ends the -+% #3 discards the res of the conditional in @add_segment, and @is_fi ends the - % conditional. - @gdef@call_the_macro#1#2!#3@fi{@is_fi #1{#2}} - -@@ -8730,7 +8778,7 @@ - % for reading the argument (slightly different in the two cases). Then, - % to read the argument, in the whole-line case, it then calls the regular - % \parsearg MAC; in the lbrace case, it calls \passargtomacro MAC. --% -+% - \def\braceorline#1{\let\macnamexxx=#1\futurelet\nchar\braceorlinexxx} - \def\braceorlinexxx{% - \ifx\nchar\bgroup -@@ -8780,9 +8828,29 @@ - % also remove a trailing comma, in case of something like this: - % @node Help-Cross, , , Cross-refs - \def\donode#1 ,#2\finishnodeparse{\dodonode #1,\finishnodeparse} --\def\dodonode#1,#2\finishnodeparse{\gdef\lastnode{#1}} -+\def\dodonode#1,#2\finishnodeparse{\gdef\lastnode{#1}\omittopnode} -+ -+% Used so that the @top node doesn't have to be wrapped in an @ifnottex -+% conditional. -+% \doignore goes to more effort to skip nested conditionals but we don't need -+% that here. -+\def\omittopnode{% -+ \ifx\lastnode\wordTop -+ \expandafter\ignorenode\fi -+} -+\def\wordTop{Top} -+ -+% Until the next @node or @bye command, divert output to a box that is not -+% output. -+\def\ignorenode{\setbox\dummybox\vbox\bgroup\def\node{\egroup\node}% -+\ignorenodebye -+} -+ -+{\let\bye\relax -+\gdef\ignorenodebye{\let\bye\ignorenodebyedef} -+\gdef\ignorenodebyedef{\egroup(`Top' node ignored)\bye}} -+% The redefinition of \bye here is because it is declared \outer - --\let\nwnode=\node - \let\lastnode=\empty - - % Write a cross-reference definition for the current node. #1 is the -@@ -8805,7 +8873,7 @@ - - % \setref{NAME}{SNT} defines a cross-reference point NAME (a node or an - % anchor), which consists of three parts: --% 1) NAME-title - the current sectioning name taken from \lastsection, -+% 1) NAME-title - the current sectioning name taken from \currentsection, - % or the anchor name. - % 2) NAME-snt - section number and type, passed as the SNT arg, or - % empty for anchors. -@@ -8827,7 +8895,7 @@ - \write\auxfile{@xrdef{#1-% #1 of \setref, expanded by the \edef - ##1}{##2}}% these are parameters of \writexrdef - }% -- \toks0 = \expandafter{\lastsection}% -+ \toks0 = \expandafter{\currentsection}% - \immediate \writexrdef{title}{\the\toks0 }% - \immediate \writexrdef{snt}{\csname #2\endcsname}% \Ynumbered etc. - \safewhatsit{\writexrdef{pg}{\folio}}% will be written later, at \shipout -@@ -8839,7 +8907,7 @@ - % automatically in xrefs, if the third arg is not explicitly specified. - % This was provided as a "secret" @set xref-automatic-section-title - % variable, now it's official. --% -+% - \parseargdef\xrefautomaticsectiontitle{% - \def\temp{#1}% - \ifx\temp\onword -@@ -8855,7 +8923,7 @@ - \fi\fi - } - --% -+% - % @xref, @pxref, and @ref generate cross-references. For \xrefX, #1 is - % the node name, #2 the name of the Info cross-reference, #3 the printed - % node name, #4 the name of the Info file, #5 the name of the printed -@@ -9008,40 +9076,34 @@ - \fi - \else - % node/anchor (non-float) references. -- % -+ % - % If we use \unhbox to print the node names, TeX does not insert - % empty discretionaries after hyphens, which means that it will not - % find a line break at a hyphen in a node names. Since some manuals - % are best written with fairly long node names, containing hyphens, - % this is a loss. Therefore, we give the text of the node name - % again, so it is as if TeX is seeing it for the first time. -- % -+ % - \ifdim \wd\printedmanualbox > 0pt - % Cross-manual reference with a printed manual name. -- % -+ % - \crossmanualxref{\cite{\printedmanual\unskip}}% - % - \else\ifdim \wd\infofilenamebox > 0pt - % Cross-manual reference with only an info filename (arg 4), no - % printed manual name (arg 5). This is essentially the same as - % the case above; we output the filename, since we have nothing else. -- % -+ % - \crossmanualxref{\code{\infofilename\unskip}}% - % - \else - % Reference within this manual. - % -- % _ (for example) has to be the character _ for the purposes of the -- % control sequence corresponding to the node, but it has to expand -- % into the usual \leavevmode...\vrule stuff for purposes of -- % printing. So we \turnoffactive for the \refx-snt, back on for the -- % printing, back off for the \refx-pg. -- {\turnoffactive -- % Only output a following space if the -snt ref is nonempty; for -- % @unnumbered and @anchor, it won't be. -- \setbox2 = \hbox{\ignorespaces \refx{#1-snt}{}}% -- \ifdim \wd2 > 0pt \refx{#1-snt}\space\fi -- }% -+ % Only output a following space if the -snt ref is nonempty; for -+ % @unnumbered and @anchor, it won't be. -+ \setbox2 = \hbox{\ignorespaces \refx{#1-snt}{}}% -+ \ifdim \wd2 > 0pt \refx{#1-snt}\space\fi -+ % - % output the `[mynode]' via the macro below so it can be overridden. - \xrefprintnodename\printedrefname - % -@@ -9065,20 +9127,20 @@ - \endgroup} - - % Output a cross-manual xref to #1. Used just above (twice). --% -+% - % Only include the text "Section ``foo'' in" if the foo is neither - % missing or Top. Thus, @xref{,,,foo,The Foo Manual} outputs simply - % "see The Foo Manual", the idea being to refer to the whole manual. --% -+% - % But, this being TeX, we can't easily compare our node name against the - % string "Top" while ignoring the possible spaces before and after in - % the input. By adding the arbitrary 7sp below, we make it much less - % likely that a real node name would have the same width as "Top" (e.g., - % in a monospaced font). Hopefully it will never happen in practice. --% -+% - % For the same basic reason, we retypeset the "Top" at every - % reference, since the current font is indeterminate. --% -+% - \def\crossmanualxref#1{% - \setbox\toprefbox = \hbox{Top\kern7sp}% - \setbox2 = \hbox{\ignorespaces \printedrefname \unskip \kern7sp}% -@@ -9125,13 +9187,13 @@ - \fi\fi\fi - } - --% \refx{NAME}{SUFFIX} - reference a cross-reference string named NAME. SUFFIX -+% \refx{NAME}{SUFFIX} - reference a cross-reference string named NAME. SUFFIX - % is output afterwards if non-empty. - \def\refx#1#2{% - \requireauxfile - {% - \indexnofonts -- \otherbackslash -+ \turnoffactive - \def\value##1{##1}% - \expandafter\global\expandafter\let\expandafter\thisrefX - \csname XR#1\endcsname -@@ -9157,9 +9219,9 @@ - #2% Output the suffix in any case. - } - --% This is the macro invoked by entries in the aux file. Define a control --% sequence for a cross-reference target (we prepend XR to the control sequence --% name to avoid collisions). The value is the page number. If this is a float -+% This is the macro invoked by entries in the aux file. Define a control -+% sequence for a cross-reference target (we prepend XR to the control sequence -+% name to avoid collisions). The value is the page number. If this is a float - % type, we have more work to do. - % - \def\xrdef#1#2{% -@@ -9175,10 +9237,10 @@ - \bgroup - \expandafter\gdef\csname XR\safexrefname\endcsname{#2}% - \egroup -- % We put the \gdef inside a group to avoid the definitions building up on -- % TeX's save stack, which can cause it to run out of space for aux files with -+ % We put the \gdef inside a group to avoid the definitions building up on -+ % TeX's save stack, which can cause it to run out of space for aux files with - % thousands of lines. \gdef doesn't use the save stack, but \csname does -- % when it defines an unknown control sequence as \relax. -+ % when it defines an unknown control sequence as \relax. - % - % Was that xref control sequence that we just defined for a float? - \expandafter\iffloat\csname XR\safexrefname\endcsname -@@ -9257,19 +9319,6 @@ - \catcode`\^^]=\other - \catcode`\^^^=\other - \catcode`\^^_=\other -- % It was suggested to set the catcode of ^ to 7, which would allow ^^e4 etc. -- % in xref tags, i.e., node names. But since ^^e4 notation isn't -- % supported in the main text, it doesn't seem desirable. Furthermore, -- % that is not enough: for node names that actually contain a ^ -- % character, we would end up writing a line like this: 'xrdef {'hat -- % b-title}{'hat b} and \xrdef does a \csname...\endcsname on the first -- % argument, and \hat is not an expandable control sequence. It could -- % all be worked out, but why? Either we support ^^ or we don't. -- % -- % The other change necessary for this was to define \auxhat: -- % \def\auxhat{\def^{'hat }}% extra space so ok if followed by letter -- % and then to call \auxhat in \setq. -- % - \catcode`\^=\other - % - % Special characters. Should be turned off anyway, but... -@@ -9287,14 +9336,7 @@ - \catcode`\%=\other - \catcode`+=\other % avoid \+ for paranoia even though we've turned it off - % -- % This is to support \ in node names and titles, since the \ -- % characters end up in a \csname. It's easier than -- % leaving it active and making its active definition an actual \ -- % character. What I don't understand is why it works in the *value* -- % of the xrdef. Seems like it should be a catcode12 \, and that -- % should not typeset properly. But it works, so I'm moving on for -- % now. --karl, 15jan04. -- \catcode`\\=\other -+ \catcode`\\=\active - % - % @ is our escape character in .aux files, and we need braces. - \catcode`\{=1 -@@ -9557,7 +9599,7 @@ - % - \ifimagevmode - \medskip % space after a standalone image -- \fi -+ \fi - \ifx\centersub\centerV \egroup \fi - \endgroup} - -@@ -9625,13 +9667,13 @@ - \global\advance\floatno by 1 - % - {% -- % This magic value for \lastsection is output by \setref as the -+ % This magic value for \currentsection is output by \setref as the - % XREFLABEL-title value. \xrefX uses it to distinguish float - % labels (which have a completely different output format) from - % node and anchor labels. And \xrdef uses it to construct the - % lists of floats. - % -- \edef\lastsection{\floatmagic=\safefloattype}% -+ \edef\currentsection{\floatmagic=\safefloattype}% - \setref{\floatlabel}{Yfloat}% - }% - \fi -@@ -9754,7 +9796,7 @@ - - % #1 is the control sequence we are passed; we expand into a conditional - % which is true if #1 represents a float ref. That is, the magic --% \lastsection value which we \setref above. -+% \currentsection value which we \setref above. - % - \def\iffloat#1{\expandafter\doiffloat#1==\finish} - % -@@ -10388,7 +10430,7 @@ - \uppercase{.} - \endgroup - \else -- \errhelp = \EMsimple -+ \errhelp = \EMsimple - \errmessage{Unicode character U+#1 not supported, sorry}% - \fi - \else -@@ -10421,7 +10463,7 @@ - \countUTFz = "#1\relax - \begingroup - \parseXMLCharref -- -+ - % Give \u8:... its definition. The sequence of seven \expandafter's - % expands after the \gdef three times, e.g. - % -@@ -10433,7 +10475,7 @@ - \expandafter\expandafter - \expandafter\expandafter - \expandafter\gdef \UTFviiiTmp{#2}% -- % -+ % - \expandafter\ifx\csname uni:#1\endcsname \relax \else - \message{Internal error, already defined: #1}% - \fi -@@ -10472,7 +10514,7 @@ - \divide\countUTFz by 64 - \countUTFy = \countUTFz % Save to be the future value of \countUTFz. - \multiply\countUTFz by 64 -- -+ - % \countUTFz is now \countUTFx with the last 5 bits cleared. Subtract - % in order to get the last five bits. - \advance\countUTFx by -\countUTFz -@@ -10507,7 +10549,7 @@ - % U+0080..U+00FF = https://en.wikipedia.org/wiki/Latin-1_Supplement_(Unicode_block) - % U+0100..U+017F = https://en.wikipedia.org/wiki/Latin_Extended-A - % U+0180..U+024F = https://en.wikipedia.org/wiki/Latin_Extended-B --% -+% - % Many of our renditions are less than wonderful, and all the missing - % characters are available somewhere. Loading the necessary fonts - % awaits user request. We can't truly support Unicode without -@@ -10808,6 +10850,8 @@ - \DeclareUnicodeCharacter{0233}{\=y}% - \DeclareUnicodeCharacter{0237}{\dotless{j}}% - % -+ \DeclareUnicodeCharacter{02BC}{'}% -+ % - \DeclareUnicodeCharacter{02DB}{\ogonek{ }}% - % - % Greek letters upper case -@@ -11242,21 +11286,14 @@ - \relax - } - --% define all Unicode characters we know about, for the sake of @U. -+% Define all Unicode characters we know about. This makes UTF-8 the default -+% input encoding and allows @U to work. - \iftxinativeunicodecapable - \nativeunicodechardefsatu - \else - \utfeightchardefs - \fi - -- --% Make non-ASCII characters printable again for compatibility with --% existing Texinfo documents that may use them, even without declaring a --% document encoding. --% --\setnonasciicharscatcode \other -- -- - \message{formatting,} - - \newdimen\defaultparindent \defaultparindent = 15pt -@@ -11449,6 +11486,18 @@ - \globaldefs = 0 - }} - -+\def\bsixpaper{{\globaldefs = 1 -+ \afourpaper -+ \internalpagesizes{140mm}{100mm}% -+ {-6.35mm}{-12.7mm}% -+ {\bindingoffset}{14pt}% -+ {176mm}{125mm}% -+ \let\SETdispenvsize=\smallword -+ \lispnarrowing = 0.2in -+ \globaldefs = 0 -+}} -+ -+ - % @pagesizes TEXTHEIGHT[,TEXTWIDTH] - % Perhaps we should allow setting the margins, \topskip, \parskip, - % and/or leading, also. Or perhaps we should compute them somehow. -@@ -11462,12 +11511,12 @@ - \setleading{\textleading}% - % - \dimen0 = #1\relax -- \advance\dimen0 by \voffset -- \advance\dimen0 by 1in % reference point for DVI is 1 inch from top of page -+ \advance\dimen0 by 2.5in % default 1in margin above heading line -+ % and 1.5in to include heading, footing and -+ % bottom margin - % - \dimen2 = \hsize -- \advance\dimen2 by \normaloffset -- \advance\dimen2 by 1in % reference point is 1 inch from left edge of page -+ \advance\dimen2 by 2in % default to 1 inch margin on each side - % - \internalpagesizes{#1}{\hsize}% - {\voffset}{\normaloffset}% -@@ -11552,9 +11601,9 @@ - \def\texinfochars{% - \let< = \activeless - \let> = \activegtr -- \let~ = \activetilde -+ \let~ = \activetilde - \let^ = \activehat -- \markupsetuplqdefault \markupsetuprqdefault -+ \markupsetuplqdefault \markupsetuprqdefault - \let\b = \strong - \let\i = \smartitalic - % in principle, all other definitions in \tex have to be undone too. -@@ -11572,11 +11621,9 @@ - % \backslashcurfont outputs one backslash character in current font, - % as in \char`\\. - \global\chardef\backslashcurfont=`\\ --\global\let\rawbackslashxx=\backslashcurfont % let existing .??s files work - --% \realbackslash is an actual character `\' with catcode other, and --% \doublebackslash is two of them (for the pdf outlines). --{\catcode`\\=\other @gdef@realbackslash{\} @gdef@doublebackslash{\\}} -+% \realbackslash is an actual character `\' with catcode other. -+{\catcode`\\=\other @gdef@realbackslash{\}} - - % In Texinfo, backslash is an active character; it prints the backslash - % in fixed width font. -@@ -11594,10 +11641,8 @@ - @def@ttbackslash{{@tt @ifmmode @mathchar29020 @else @backslashcurfont @fi}} - @let@backslashchar = @ttbackslash % @backslashchar{} is for user documents. - --% \rawbackslash defines an active \ to do \backslashcurfont. - % \otherbackslash defines an active \ to be a literal `\' character with --% catcode other. We switch back and forth between these. --@gdef@rawbackslash{@let\=@backslashcurfont} -+% catcode other. - @gdef@otherbackslash{@let\=@realbackslash} - - % Same as @turnoffactive except outputs \ as {\tt\char`\\} instead of -@@ -11669,7 +11714,7 @@ - @ifx\@eatinput @let\ = @ttbackslash @fi - @catcode13=5 % regular end of line - @enableemergencynewline -- @let@c=@texinfoc -+ @let@c=@comment - @let@parsearg@originalparsearg - % Also turn back on active characters that might appear in the input - % file name, in case not using a pre-dumped format. -@@ -11715,7 +11760,7 @@ - @markupsetuprqdefault - - @c Local variables: --@c eval: (add-hook 'write-file-hooks 'time-stamp) -+@c eval: (add-hook 'before-save-hook 'time-stamp) - @c page-delimiter: "^\\\\message\\|emacs-page" - @c time-stamp-start: "def\\\\texinfoversion{" - @c time-stamp-format: "%:y-%02m-%02d.%02H" -diff -ur libffi-3.3/fficonfig.h.in libffi-3.3.new/fficonfig.h.in ---- libffi-3.3/fficonfig.h.in 2019-11-01 03:30:04.000000000 -0600 -+++ libffi-3.3.new/fficonfig.h.in 2021-01-04 19:48:48.000000000 -0700 -@@ -32,6 +32,10 @@ - /* Define this if you do not want support for aggregate types. */ - #undef FFI_NO_STRUCTS - -+/* Creating a separate libffi-trampolines.dylib and remapping the entire dylib -+ */ -+#undef FFI_TRAMPOLINE_WHOLE_DYLIB -+ - /* Define to 1 if you have `alloca', as a function or macro. */ - #undef HAVE_ALLOCA - -@@ -94,6 +98,9 @@ - /* Define if read-only mmap of a plain file works. */ - #undef HAVE_MMAP_FILE - -+/* Define if your compiler supports pointer authentication. */ -+#undef HAVE_PTRAUTH -+ - /* Define if .eh_frame sections should be read-only. */ - #undef HAVE_RO_EH_FRAME - -diff -ur libffi-3.3/include/Makefile.in libffi-3.3.new/include/Makefile.in ---- libffi-3.3/include/Makefile.in 2019-11-23 06:59:04.000000000 -0700 -+++ libffi-3.3.new/include/Makefile.in 2021-01-04 19:48:49.000000000 -0700 -@@ -1,7 +1,7 @@ --# Makefile.in generated by automake 1.16.1 from Makefile.am. -+# Makefile.in generated by automake 1.16.3 from Makefile.am. - # @configure_input@ - --# Copyright (C) 1994-2018 Free Software Foundation, Inc. -+# Copyright (C) 1994-2020 Free Software Foundation, Inc. - - # This Makefile.in is free software; the Free Software Foundation - # gives unlimited permission to copy and/or distribute it, -diff -ur libffi-3.3/include/ffi.h.in libffi-3.3.new/include/ffi.h.in ---- libffi-3.3/include/ffi.h.in 2019-11-13 05:57:22.000000000 -0700 -+++ libffi-3.3.new/include/ffi.h.in 2021-01-04 19:39:16.000000000 -0700 -@@ -349,6 +349,11 @@ - void *user_data, - void*codeloc); - -+#if defined(__x86_64__) || defined(__arm64__) -+FFI_API ffi_closure * -+ffi_find_closure_for_code(void *code); -+#endif -+ - #ifdef __sgi - # pragma pack 8 - #endif -diff -ur libffi-3.3/install-sh libffi-3.3.new/install-sh ---- libffi-3.3/install-sh 2019-11-01 03:30:05.000000000 -0600 -+++ libffi-3.3.new/install-sh 2021-01-04 19:48:49.000000000 -0700 -@@ -1,7 +1,7 @@ - #!/bin/sh - # install - install a program, script, or datafile - --scriptversion=2018-03-11.20; # UTC -+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 -@@ -69,6 +69,11 @@ - # 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= -@@ -99,18 +104,28 @@ - --version display version info and exit. - - -c (ignored) -- -C install only if different (preserve the last data modification time) -+ -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 -@@ -137,8 +152,13 @@ - -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 -@@ -255,6 +275,10 @@ - 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 -@@ -301,22 +325,6 @@ - if test $dstdir_status != 0; then - case $posix_mkdir in - '') -- # Create intermediate dirs using mode 755 as modified by the umask. -- # This is like FreeBSD 'install' as of 1997-10-28. -- umask=`umask` -- case $stripcmd.$umask in -- # Optimize common cases. -- *[2367][2367]) mkdir_umask=$umask;; -- .*0[02][02] | .[02][02] | .[02]) mkdir_umask=22;; -- -- *[0-7]) -- mkdir_umask=`expr $umask + 22 \ -- - $umask % 100 % 40 + $umask % 20 \ -- - $umask % 10 % 4 + $umask % 2 -- `;; -- *) mkdir_umask=$umask,go-w;; -- esac -- - # With -d, create the new directory with the user-specified mode. - # Otherwise, rely on $mkdir_umask. - if test -n "$dir_arg"; then -@@ -326,52 +334,49 @@ - fi - - posix_mkdir=false -- case $umask in -- *[123567][0-7][0-7]) -- # POSIX mkdir -p sets u+wx bits regardless of umask, which -- # is incompatible with FreeBSD 'install' when (umask & 300) != 0. -- ;; -- *) -- # Note that $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' feature. -- 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;; -+ # 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 -@@ -382,7 +387,7 @@ - then : - else - -- # The umask is ridiculous, or mkdir does not conform to POSIX, -+ # 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. - -@@ -411,7 +416,7 @@ - prefixes= - else - if $posix_mkdir; then -- (umask=$mkdir_umask && -+ (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 -@@ -451,7 +456,18 @@ - trap 'ret=$?; rm -f "$dsttmp" "$rmtmp" && exit $ret' 0 - - # Copy the file name to the temp name. -- (umask $cp_umask && $doit_exec $cpprog "$src" "$dsttmp") && -+ (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. - # -@@ -477,6 +493,13 @@ - 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 || - -@@ -491,9 +514,9 @@ - # file should still install successfully. - { - test ! -f "$dst" || -- $doit $rmcmd -f "$dst" 2>/dev/null || -+ $doit $rmcmd "$dst" 2>/dev/null || - { $doit $mvcmd -f "$dst" "$rmtmp" 2>/dev/null && -- { $doit $rmcmd -f "$rmtmp" 2>/dev/null; :; } -+ { $doit $rmcmd "$rmtmp" 2>/dev/null; :; } - } || - { echo "$0: cannot unlink or rename $dst" >&2 - (exit 1); exit 1 -diff -ur libffi-3.3/ltmain.sh libffi-3.3.new/ltmain.sh ---- libffi-3.3/ltmain.sh 2019-11-01 03:30:00.000000000 -0600 -+++ libffi-3.3.new/ltmain.sh 2021-01-04 19:48:46.000000000 -0700 -@@ -2124,7 +2124,7 @@ - # a configuration failure hint, and exit. - func_fatal_configuration () - { -- func_fatal_error ${1+"$@"} \ -+ func__fatal_error ${1+"$@"} \ - "See the $PACKAGE documentation for more information." \ - "Fatal configuration error." - } -@@ -7272,12 +7272,10 @@ - # -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 - -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=*) -+ -O*|-g*|-flto*|-fwhopr*|-fuse-linker-plugin|-fstack-protector*|-stdlib=*) - func_quote_for_eval "$arg" - arg=$func_quote_for_eval_result - func_append compile_command " $arg" -diff -ur libffi-3.3/m4/libtool.m4 libffi-3.3.new/m4/libtool.m4 ---- libffi-3.3/m4/libtool.m4 2019-11-01 03:30:00.000000000 -0600 -+++ libffi-3.3.new/m4/libtool.m4 2021-01-04 19:48:46.000000000 -0700 -@@ -1067,16 +1067,11 @@ - _lt_dar_allow_undefined='$wl-undefined ${wl}suppress' ;; - darwin1.*) - _lt_dar_allow_undefined='$wl-flat_namespace $wl-undefined ${wl}suppress' ;; -- darwin*) # darwin 5.x on -- # if running on 10.5 or later, the deployment target defaults -- # to the OS version, if on x86, and 10.4, the deployment -- # target defaults to 10.4. Don't you love it? -- case ${MACOSX_DEPLOYMENT_TARGET-10.0},$host in -- 10.0,*86*-darwin8*|10.0,*-darwin[[91]]*) -- _lt_dar_allow_undefined='$wl-undefined ${wl}dynamic_lookup' ;; -- 10.[[012]][[,.]]*) -+ darwin*) -+ case ${MACOSX_DEPLOYMENT_TARGET},$host in -+ 10.[[012]],*|,*powerpc*) - _lt_dar_allow_undefined='$wl-flat_namespace $wl-undefined ${wl}suppress' ;; -- 10.*) -+ *) - _lt_dar_allow_undefined='$wl-undefined ${wl}dynamic_lookup' ;; - esac - ;; -@@ -2867,9 +2862,6 @@ - # 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 -@@ -2878,7 +2870,7 @@ - # 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" -+ sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra" - fi - - # We used to test for /lib/ld.so.1 and disable shared libraries on -diff -ur libffi-3.3/man/Makefile.in libffi-3.3.new/man/Makefile.in ---- libffi-3.3/man/Makefile.in 2019-11-23 06:59:04.000000000 -0700 -+++ libffi-3.3.new/man/Makefile.in 2021-01-04 19:48:49.000000000 -0700 -@@ -1,7 +1,7 @@ --# Makefile.in generated by automake 1.16.1 from Makefile.am. -+# Makefile.in generated by automake 1.16.3 from Makefile.am. - # @configure_input@ - --# Copyright (C) 1994-2018 Free Software Foundation, Inc. -+# Copyright (C) 1994-2020 Free Software Foundation, Inc. - - # This Makefile.in is free software; the Free Software Foundation - # gives unlimited permission to copy and/or distribute it, -diff -ur libffi-3.3/missing libffi-3.3.new/missing ---- libffi-3.3/missing 2019-11-01 03:30:05.000000000 -0600 -+++ libffi-3.3.new/missing 2021-01-04 19:48:49.000000000 -0700 -@@ -3,7 +3,7 @@ - - scriptversion=2018-03-07.03; # UTC - --# Copyright (C) 1996-2018 Free Software Foundation, Inc. -+# Copyright (C) 1996-2020 Free Software Foundation, Inc. - # Originally written by Fran,cois Pinard , 1996. - - # This program is free software; you can redistribute it and/or modify -diff -ur libffi-3.3/src/aarch64/ffi.c libffi-3.3.new/src/aarch64/ffi.c ---- libffi-3.3/src/aarch64/ffi.c 2019-10-31 08:49:54.000000000 -0600 -+++ libffi-3.3.new/src/aarch64/ffi.c 2021-01-04 19:40:32.000000000 -0700 -@@ -62,6 +62,9 @@ - #if FFI_EXEC_TRAMPOLINE_TABLE - - #ifdef __MACH__ -+#ifdef HAVE_PTRAUTH -+#include -+#endif - #include - #endif - -@@ -599,11 +602,12 @@ - else if (flags & AARCH64_RET_NEED_COPY) - rsize = 16; - -- /* Allocate consectutive stack for everything we'll need. */ -- context = alloca (sizeof(struct call_context) + stack_bytes + 32 + rsize); -+ /* Allocate consectutive stack for everything we'll need. -+ The frame uses 40 bytes for: lr, fp, rvalue, flags, sp */ -+ context = alloca (sizeof(struct call_context) + stack_bytes + 40 + rsize); - stack = context + 1; - frame = (void*)((uintptr_t)stack + (uintptr_t)stack_bytes); -- rvalue = (rsize ? (void*)((uintptr_t)frame + 32) : orig_rvalue); -+ rvalue = (rsize ? (void*)((uintptr_t)frame + 40) : orig_rvalue); - - arg_init (&state); - for (i = 0, nargs = cif->nargs; i < nargs; i++) -@@ -643,12 +647,13 @@ - state.ngrn = N_X_ARG_REG; - /* Note that the default abi extends each argument - to a full 64-bit slot, while the iOS abi allocates -- only enough space. */ -+ only enough space, except for variadic arguments. */ - #ifdef __APPLE__ -- memcpy(d, a, s); --#else -- *(ffi_arg *)d = ext; -+ if (!state.allocating_variadic) -+ memcpy(d, a, s); -+ else - #endif -+ *(ffi_arg *)d = ext; - } - } - break; -@@ -756,6 +761,8 @@ - ffi_call_int (cif, fn, rvalue, avalue, NULL); - } - -+#if FFI_CLOSURES -+ - #ifdef FFI_GO_CLOSURES - void - ffi_call_go (ffi_cif *cif, void (*fn) (void), void *rvalue, -@@ -789,7 +796,14 @@ - - #if FFI_EXEC_TRAMPOLINE_TABLE - #ifdef __MACH__ -+#ifdef HAVE_PTRAUTH -+ codeloc = ptrauth_auth_data(codeloc, ptrauth_key_function_pointer, 0); -+#endif -+#ifdef FFI_TRAMPOLINE_WHOLE_DYLIB -+ void **config = (void **)((uint8_t *)codeloc - 2*PAGE_MAX_SIZE); -+#else - void **config = (void **)((uint8_t *)codeloc - PAGE_MAX_SIZE); -+#endif - config[0] = closure; - config[1] = start; - #endif -@@ -825,6 +839,22 @@ - return FFI_OK; - } - -+ffi_closure * -+ffi_find_closure_for_code(void *codeloc) -+{ -+#if FFI_EXEC_TRAMPOLINE_TABLE -+# ifdef FFI_TRAMPOLINE_WHOLE_DYLIB -+ void **config = (void **)((uint8_t *)codeloc - 2*PAGE_MAX_SIZE); -+# else -+ void **config = (void **)((uint8_t *)codeloc - PAGE_MAX_SIZE); -+# endif -+ return config[0]; -+#else -+ return (ffi_closure*)codeloc; -+#endif -+} -+ -+ - #ifdef FFI_GO_CLOSURES - extern void ffi_go_closure_SYSV (void) FFI_HIDDEN; - extern void ffi_go_closure_SYSV_V (void) FFI_HIDDEN; -@@ -1006,4 +1036,6 @@ - return flags; - } - -+#endif /* FFI_CLOSURES */ -+ - #endif /* (__aarch64__) || defined(__arm64__)|| defined (_M_ARM64)*/ -diff -ur libffi-3.3/src/aarch64/internal.h libffi-3.3.new/src/aarch64/internal.h ---- libffi-3.3/src/aarch64/internal.h 2019-10-31 08:49:54.000000000 -0600 -+++ libffi-3.3.new/src/aarch64/internal.h 2021-01-04 19:39:16.000000000 -0700 -@@ -65,3 +65,24 @@ - #define N_X_ARG_REG 8 - #define N_V_ARG_REG 8 - #define CALL_CONTEXT_SIZE (N_V_ARG_REG * 16 + N_X_ARG_REG * 8) -+ -+/* Helpers for writing assembly compatible with arm ptr auth */ -+#ifdef LIBFFI_ASM -+ -+#ifdef HAVE_PTRAUTH -+#define SIGN_LR pacibsp -+#define SIGN_LR_WITH_REG(x) pacib lr, x -+#define AUTH_LR_AND_RET retab -+#define AUTH_LR_WITH_REG(x) autib lr, x -+#define BRANCH_AND_LINK_TO_REG blraaz -+#define BRANCH_TO_REG braaz -+#else -+#define SIGN_LR -+#define SIGN_LR_WITH_REG(x) -+#define AUTH_LR_AND_RET ret -+#define AUTH_LR_WITH_REG(x) -+#define BRANCH_AND_LINK_TO_REG blr -+#define BRANCH_TO_REG br -+#endif -+ -+#endif -diff -ur libffi-3.3/src/aarch64/sysv.S libffi-3.3.new/src/aarch64/sysv.S ---- libffi-3.3/src/aarch64/sysv.S 2019-10-31 08:49:54.000000000 -0600 -+++ libffi-3.3.new/src/aarch64/sysv.S 2021-01-04 19:40:21.000000000 -0700 -@@ -78,9 +78,22 @@ - - cfi_startproc - CNAME(ffi_call_SYSV): -+ /* Sign the lr with x1 since that is where it will be stored */ -+ SIGN_LR_WITH_REG(x1) -+ - /* Use a stack frame allocated by our caller. */ -- cfi_def_cfa(x1, 32); -+#if defined(HAVE_PTRAUTH) && defined(__APPLE__) -+ /* darwin's libunwind assumes that the cfa is the sp and that's the data -+ * used to sign the lr. In order to allow unwinding through this -+ * function it is necessary to point the cfa at the signing register. -+ */ -+ cfi_def_cfa(x1, 0); -+#else -+ cfi_def_cfa(x1, 40); -+#endif - stp x29, x30, [x1] -+ mov x9, sp -+ str x9, [x1, #32] - mov x29, x1 - mov sp, x0 - cfi_def_cfa_register(x29) -@@ -111,13 +124,15 @@ - /* Deallocate the context, leaving the stacked arguments. */ - add sp, sp, #CALL_CONTEXT_SIZE - -- blr x9 /* call fn */ -+ BRANCH_AND_LINK_TO_REG x9 /* call fn */ - - ldp x3, x4, [x29, #16] /* reload rvalue and flags */ - - /* Partially deconstruct the stack frame. */ -- mov sp, x29 -+ ldr x9, [x29, #32] -+ mov sp, x9 - cfi_def_cfa_register (sp) -+ mov x2, x29 /* Preserve for auth */ - ldp x29, x30, [x29] - - /* Save the return value as directed. */ -@@ -131,71 +146,76 @@ - and therefore we want to extend to 64 bits; these types - have two consecutive entries allocated for them. */ - .align 4 --0: ret /* VOID */ -+0: b 99f /* VOID */ - nop - 1: str x0, [x3] /* INT64 */ -- ret -+ b 99f - 2: stp x0, x1, [x3] /* INT128 */ -- ret -+ b 99f - 3: brk #1000 /* UNUSED */ -- ret -+ b 99f - 4: brk #1000 /* UNUSED */ -- ret -+ b 99f - 5: brk #1000 /* UNUSED */ -- ret -+ b 99f - 6: brk #1000 /* UNUSED */ -- ret -+ b 99f - 7: brk #1000 /* UNUSED */ -- ret -+ b 99f - 8: st4 { v0.s, v1.s, v2.s, v3.s }[0], [x3] /* S4 */ -- ret -+ b 99f - 9: st3 { v0.s, v1.s, v2.s }[0], [x3] /* S3 */ -- ret -+ b 99f - 10: stp s0, s1, [x3] /* S2 */ -- ret -+ b 99f - 11: str s0, [x3] /* S1 */ -- ret -+ b 99f - 12: st4 { v0.d, v1.d, v2.d, v3.d }[0], [x3] /* D4 */ -- ret -+ b 99f - 13: st3 { v0.d, v1.d, v2.d }[0], [x3] /* D3 */ -- ret -+ b 99f - 14: stp d0, d1, [x3] /* D2 */ -- ret -+ b 99f - 15: str d0, [x3] /* D1 */ -- ret -+ b 99f - 16: str q3, [x3, #48] /* Q4 */ - nop - 17: str q2, [x3, #32] /* Q3 */ - nop - 18: stp q0, q1, [x3] /* Q2 */ -- ret -+ b 99f - 19: str q0, [x3] /* Q1 */ -- ret -+ b 99f - 20: uxtb w0, w0 /* UINT8 */ - str x0, [x3] --21: ret /* reserved */ -+21: b 99f /* reserved */ - nop - 22: uxth w0, w0 /* UINT16 */ - str x0, [x3] --23: ret /* reserved */ -+23: b 99f /* reserved */ - nop - 24: mov w0, w0 /* UINT32 */ - str x0, [x3] --25: ret /* reserved */ -+25: b 99f /* reserved */ - nop - 26: sxtb x0, w0 /* SINT8 */ - str x0, [x3] --27: ret /* reserved */ -+27: b 99f /* reserved */ - nop - 28: sxth x0, w0 /* SINT16 */ - str x0, [x3] --29: ret /* reserved */ -+29: b 99f /* reserved */ - nop - 30: sxtw x0, w0 /* SINT32 */ - str x0, [x3] --31: ret /* reserved */ -+31: b 99f /* reserved */ - nop - -+ /* Return now that result has been populated. */ -+99: -+ AUTH_LR_WITH_REG(x2) -+ ret -+ - cfi_endproc - - .globl CNAME(ffi_call_SYSV) -@@ -205,6 +225,8 @@ - .size CNAME(ffi_call_SYSV), .-CNAME(ffi_call_SYSV) - #endif - -+#if FFI_CLOSURES -+ - /* ffi_closure_SYSV - - Closure invocation glue. This is the low level code invoked directly by -@@ -224,6 +246,7 @@ - .align 4 - CNAME(ffi_closure_SYSV_V): - cfi_startproc -+ SIGN_LR - stp x29, x30, [sp, #-ffi_closure_SYSV_FS]! - cfi_adjust_cfa_offset (ffi_closure_SYSV_FS) - cfi_rel_offset (x29, 0) -@@ -247,6 +270,7 @@ - .align 4 - cfi_startproc - CNAME(ffi_closure_SYSV): -+ SIGN_LR - stp x29, x30, [sp, #-ffi_closure_SYSV_FS]! - cfi_adjust_cfa_offset (ffi_closure_SYSV_FS) - cfi_rel_offset (x29, 0) -@@ -263,7 +287,9 @@ - /* Load ffi_closure_inner arguments. */ - ldp PTR_REG(0), PTR_REG(1), [x17, #FFI_TRAMPOLINE_CLOSURE_OFFSET] /* load cif, fn */ - ldr PTR_REG(2), [x17, #FFI_TRAMPOLINE_CLOSURE_OFFSET+PTR_SIZE*2] /* load user_data */ -+#ifdef FFI_GO_CLOSURES - .Ldo_closure: -+#endif - add x3, sp, #16 /* load context */ - add x4, sp, #ffi_closure_SYSV_FS /* load stack */ - add x5, sp, #16+CALL_CONTEXT_SIZE /* load rvalue */ -@@ -346,7 +372,7 @@ - cfi_adjust_cfa_offset (-ffi_closure_SYSV_FS) - cfi_restore (x29) - cfi_restore (x30) -- ret -+ AUTH_LR_AND_RET - cfi_endproc - - .globl CNAME(ffi_closure_SYSV) -@@ -432,6 +458,7 @@ - .size CNAME(ffi_go_closure_SYSV), . - CNAME(ffi_go_closure_SYSV) - #endif - #endif /* FFI_GO_CLOSURES */ -+#endif /* FFI_CLOSURES */ - #endif /* __arm64__ */ - - #if defined __ELF__ && defined __linux__ -Only in libffi-3.3.new/src/aarch64: trampoline.S -diff -ur libffi-3.3/src/arm/ffi.c libffi-3.3.new/src/arm/ffi.c ---- libffi-3.3/src/arm/ffi.c 2019-10-31 08:49:54.000000000 -0600 -+++ libffi-3.3.new/src/arm/ffi.c 2021-01-04 19:39:16.000000000 -0700 -@@ -421,12 +421,14 @@ - ffi_call_int (cif, fn, rvalue, avalue, NULL); - } - -+#ifdef FFI_GO_CLOSURES - void - ffi_call_go (ffi_cif *cif, void (*fn) (void), void *rvalue, - void **avalue, void *closure) - { - ffi_call_int (cif, fn, rvalue, avalue, closure); - } -+#endif - - static void * - ffi_prep_incoming_args_SYSV (ffi_cif *cif, void *rvalue, -@@ -529,6 +531,8 @@ - return rvalue; - } - -+#if FFI_CLOSURES -+ - struct closure_frame - { - char vfp_space[8*8] __attribute__((aligned(8))); -@@ -564,8 +568,11 @@ - - void ffi_closure_SYSV (void) FFI_HIDDEN; - void ffi_closure_VFP (void) FFI_HIDDEN; -+ -+#ifdef FFI_GO_CLOSURES - void ffi_go_closure_SYSV (void) FFI_HIDDEN; - void ffi_go_closure_VFP (void) FFI_HIDDEN; -+#endif - - /* the cif must already be prep'ed */ - -@@ -622,6 +629,7 @@ - return FFI_OK; - } - -+#ifdef FFI_GO_CLOSURES - ffi_status - ffi_prep_go_closure (ffi_go_closure *closure, ffi_cif *cif, - void (*fun) (ffi_cif *, void *, void **, void *)) -@@ -643,6 +651,9 @@ - - return FFI_OK; - } -+#endif -+ -+#endif /* FFI_CLOSURES */ - - /* Below are routines for VFP hard-float support. */ - -diff -ur libffi-3.3/src/arm/sysv.S libffi-3.3.new/src/arm/sysv.S ---- libffi-3.3/src/arm/sysv.S 2019-10-31 08:49:54.000000000 -0600 -+++ libffi-3.3.new/src/arm/sysv.S 2021-01-04 19:39:16.000000000 -0700 -@@ -208,6 +208,7 @@ - UNWIND(.fnend) - ARM_FUNC_END(ffi_call_SYSV) - -+#if FFI_CLOSURES - - /* - int ffi_closure_inner_* (cif, fun, user_data, frame) -@@ -354,6 +355,8 @@ - cfi_endproc - ARM_FUNC_END(ffi_closure_ret) - -+#endif /* FFI_CLOSURES */ -+ - #if FFI_EXEC_TRAMPOLINE_TABLE - - #ifdef __MACH__ -diff -ur libffi-3.3/src/closures.c libffi-3.3.new/src/closures.c ---- libffi-3.3/src/closures.c 2019-11-20 04:15:41.000000000 -0700 -+++ libffi-3.3.new/src/closures.c 2021-01-04 19:39:16.000000000 -0700 -@@ -148,10 +148,19 @@ - - #include - #include -+#ifdef HAVE_PTRAUTH -+#include -+#endif - #include - #include - -+#ifdef FFI_TRAMPOLINE_WHOLE_DYLIB -+#include -+#include -+#include -+#else - extern void *ffi_closure_trampoline_table_page; -+#endif - - typedef struct ffi_trampoline_table ffi_trampoline_table; - typedef struct ffi_trampoline_table_entry ffi_trampoline_table_entry; -@@ -160,7 +169,6 @@ - { - /* contiguous writable and executable pages */ - vm_address_t config_page; -- vm_address_t trampoline_page; - - /* free list tracking */ - uint16_t free_count; -@@ -180,6 +188,21 @@ struct ffi_trampoline_table_entry - /* Total number of trampolines that fit in one trampoline table */ - #define FFI_TRAMPOLINE_COUNT (PAGE_MAX_SIZE / FFI_TRAMPOLINE_SIZE) - -+/* The trampoline dylib has one page for the MACHO_HEADER and one page for the -+ * trampolines. iOS 12.0 and later, and macOS on Apple Silicon require that -+ * the entire dylib needs to be remapped as a unit. -+ * -+ * arm (legacy): Allocate two pages -- a config page and a placeholder for the trampolines -+ * arm64 (modern): Allocate three pages -- a config page and two placeholders for the trampoline dylib -+ */ -+#ifdef FFI_TRAMPOLINE_WHOLE_DYLIB -+#define FFI_TRAMPOLINE_ALLOCATION_PAGE_COUNT 3 -+#define FFI_TRAMPOLINE_PAGE_SEGMENT_OFFSET PAGE_MAX_SIZE -+#else -+#define FFI_TRAMPOLINE_ALLOCATION_PAGE_COUNT 2 -+#define FFI_TRAMPOLINE_PAGE_SEGMENT_OFFSET 0 -+#endif -+ - static pthread_mutex_t ffi_trampoline_lock = PTHREAD_MUTEX_INITIALIZER; - static ffi_trampoline_table *ffi_trampoline_tables = NULL; - -@@ -195,34 +218,67 @@ - kern_return_t kt; - uint16_t i; - -- /* Allocate two pages -- a config page and a placeholder page */ - config_page = 0x0; -- kt = vm_allocate (mach_task_self (), &config_page, PAGE_MAX_SIZE * 2, -+ /* The entire allocation is: -+ * config_page -+ * trampoline_segment -+ * -+ * trampoline_segment is: -+ * trampoline dylib mach-o header (if FFI_TRAMPOLINE_WHOLE_DYLIB) -+ * trampoline page -+ */ -+ kt = vm_allocate (mach_task_self (), &config_page, FFI_TRAMPOLINE_ALLOCATION_PAGE_COUNT * PAGE_MAX_SIZE, - VM_FLAGS_ANYWHERE); - if (kt != KERN_SUCCESS) - return NULL; - -- /* Remap the trampoline table on top of the placeholder page */ -- trampoline_page = config_page + PAGE_MAX_SIZE; -- trampoline_page_template = (vm_address_t)&ffi_closure_trampoline_table_page; -+ static void *trampoline_table_page; -+ -+#ifdef FFI_TRAMPOLINE_WHOLE_DYLIB -+ static dispatch_once_t trampoline_template_init_once; -+ -+ dispatch_once(&trampoline_template_init_once, ^{ -+ void * const trampoline_handle = dlopen("/usr/lib/libffi-trampolines.dylib", RTLD_NOW | RTLD_LOCAL | RTLD_FIRST); -+ assert(trampoline_handle); -+ -+ trampoline_table_page = dlsym(trampoline_handle, "ffi_closure_trampoline_table_page"); -+ assert(trampoline_table_page); -+ }); -+#else -+ trampoline_table_page = &ffi_closure_trampoline_table_page; -+#endif -+ -+#ifdef HAVE_PTRAUTH -+ trampoline_page_template = (uintptr_t)ptrauth_auth_data(trampoline_table_page, ptrauth_key_function_pointer, 0); -+#else -+ trampoline_page_template = (uintptr_t)trampoline_table_page; -+#endif -+ - #ifdef __arm__ - /* ffi_closure_trampoline_table_page can be thumb-biased on some ARM archs */ - trampoline_page_template &= ~1UL; - #endif -- kt = vm_remap (mach_task_self (), &trampoline_page, PAGE_MAX_SIZE, 0x0, -- VM_FLAGS_OVERWRITE, mach_task_self (), trampoline_page_template, -+ -+ vm_address_t trampoline_segment_template = trampoline_page_template - FFI_TRAMPOLINE_PAGE_SEGMENT_OFFSET; -+ vm_size_t trampoline_segment_size = (FFI_TRAMPOLINE_ALLOCATION_PAGE_COUNT - 1) * PAGE_MAX_SIZE; -+ -+ /* Remap the trampoline table on top of the placeholder page */ -+ vm_address_t trampoline_segment = config_page + PAGE_MAX_SIZE; -+ kt = vm_remap (mach_task_self(), &trampoline_segment, trampoline_segment_size, 0x0, -+ VM_FLAGS_FIXED | VM_FLAGS_OVERWRITE, mach_task_self(), trampoline_segment_template, - FALSE, &cur_prot, &max_prot, VM_INHERIT_SHARE); -- if (kt != KERN_SUCCESS) -+ if (kt != KERN_SUCCESS || !(cur_prot & VM_PROT_EXECUTE)) - { -- vm_deallocate (mach_task_self (), config_page, PAGE_MAX_SIZE * 2); -+ vm_deallocate (mach_task_self (), config_page, FFI_TRAMPOLINE_ALLOCATION_PAGE_COUNT * PAGE_MAX_SIZE); - return NULL; - } - -+ trampoline_page = trampoline_segment + FFI_TRAMPOLINE_PAGE_SEGMENT_OFFSET; -+ - /* We have valid trampoline and config pages */ - table = calloc (1, sizeof (ffi_trampoline_table)); - table->free_count = FFI_TRAMPOLINE_COUNT; - table->config_page = config_page; -- table->trampoline_page = trampoline_page; - - /* Create and initialize the free list */ - table->free_list_pool = -@@ -232,7 +278,10 @@ - { - ffi_trampoline_table_entry *entry = &table->free_list_pool[i]; - entry->trampoline = -- (void *) (table->trampoline_page + (i * FFI_TRAMPOLINE_SIZE)); -+ (void *) (trampoline_page + (i * FFI_TRAMPOLINE_SIZE)); -+#ifdef HAVE_PTRAUTH -+ entry->trampoline = ptrauth_sign_unauthenticated(entry->trampoline, ptrauth_key_function_pointer, 0); -+#endif - - if (i < table->free_count - 1) - entry->next = &table->free_list_pool[i + 1]; -diff -ur libffi-3.3/src/x86/ffi.c libffi-3.3.new/src/x86/ffi.c ---- libffi-3.3/src/x86/ffi.c 2019-10-31 08:49:54.000000000 -0600 -+++ libffi-3.3.new/src/x86/ffi.c 2021-01-04 19:38:38.000000000 -0700 -@@ -397,12 +397,14 @@ - ffi_call_int (cif, fn, rvalue, avalue, NULL); - } - -+#ifdef FFI_GO_CLOSURES - void - ffi_call_go (ffi_cif *cif, void (*fn)(void), void *rvalue, - void **avalue, void *closure) - { - ffi_call_int (cif, fn, rvalue, avalue, closure); - } -+#endif - - /** private members **/ - -@@ -572,6 +574,8 @@ - return FFI_OK; - } - -+#ifdef FFI_GO_CLOSURES -+ - void FFI_HIDDEN ffi_go_closure_EAX(void); - void FFI_HIDDEN ffi_go_closure_ECX(void); - void FFI_HIDDEN ffi_go_closure_STDCALL(void); -@@ -608,6 +612,8 @@ - return FFI_OK; - } - -+#endif /* FFI_GO_CLOSURES */ -+ - /* ------- Native raw API support -------------------------------- */ - - #if !FFI_NO_RAW_API -diff -ur libffi-3.3/src/x86/ffi64.c libffi-3.3.new/src/x86/ffi64.c ---- libffi-3.3/src/x86/ffi64.c 2019-10-31 08:49:54.000000000 -0600 -+++ libffi-3.3.new/src/x86/ffi64.c 2021-01-04 19:39:16.000000000 -0700 -@@ -688,6 +688,8 @@ - ffi_call_int (cif, fn, rvalue, avalue, NULL); - } - -+#ifdef FFI_GO_CLOSURES -+ - #ifndef __ILP32__ - extern void - ffi_call_go_efi64(ffi_cif *cif, void (*fn)(void), void *rvalue, -@@ -708,6 +710,7 @@ - ffi_call_int (cif, fn, rvalue, avalue, closure); - } - -+#endif /* FFI_GO_CLOSURES */ - - extern void ffi_closure_unix64(void) FFI_HIDDEN; - extern void ffi_closure_unix64_sse(void) FFI_HIDDEN; -@@ -761,6 +764,12 @@ - return FFI_OK; - } - -+ffi_closure * -+ffi_find_closure_for_code(void *code) -+{ -+ return (ffi_closure *) code; -+} -+ - int FFI_HIDDEN - ffi_closure_unix64_inner(ffi_cif *cif, - void (*fun)(ffi_cif*, void*, void**, void*), -@@ -854,6 +863,8 @@ - return flags; - } - -+#ifdef FFI_GO_CLOSURES -+ - extern void ffi_go_closure_unix64(void) FFI_HIDDEN; - extern void ffi_go_closure_unix64_sse(void) FFI_HIDDEN; - -@@ -883,4 +894,6 @@ - return FFI_OK; - } - -+#endif /* FFI_GO_CLOSURES */ -+ - #endif /* __x86_64__ */ -diff -ur libffi-3.3/src/x86/ffiw64.c libffi-3.3.new/src/x86/ffiw64.c ---- libffi-3.3/src/x86/ffiw64.c 2019-10-31 08:49:54.000000000 -0600 -+++ libffi-3.3.new/src/x86/ffiw64.c 2021-01-04 19:38:38.000000000 -0700 -@@ -187,7 +187,10 @@ - - - extern void ffi_closure_win64(void) FFI_HIDDEN; -+ -+#ifdef FFI_GO_CLOSURES - extern void ffi_go_closure_win64(void) FFI_HIDDEN; -+#endif - - ffi_status - EFI64(ffi_prep_closure_loc)(ffi_closure* closure, -@@ -225,6 +228,7 @@ - return FFI_OK; - } - -+#ifdef FFI_GO_CLOSURES - ffi_status - EFI64(ffi_prep_go_closure)(ffi_go_closure* closure, ffi_cif* cif, - void (*fun)(ffi_cif*, void*, void**, void*)) -@@ -244,6 +248,7 @@ - - return FFI_OK; - } -+#endif - - struct win64_closure_frame - { -diff -ur libffi-3.3/testsuite/Makefile.in libffi-3.3.new/testsuite/Makefile.in ---- libffi-3.3/testsuite/Makefile.in 2019-11-23 08:50:18.000000000 -0700 -+++ libffi-3.3.new/testsuite/Makefile.in 2021-01-04 19:48:49.000000000 -0700 -@@ -1,7 +1,7 @@ --# Makefile.in generated by automake 1.16.1 from Makefile.am. -+# Makefile.in generated by automake 1.16.3 from Makefile.am. - # @configure_input@ - --# Copyright (C) 1994-2018 Free Software Foundation, Inc. -+# Copyright (C) 1994-2020 Free Software Foundation, Inc. - - # This Makefile.in is free software; the Free Software Foundation - # gives unlimited permission to copy and/or distribute it, -@@ -462,7 +462,7 @@ - @echo '# Do not edit here. If you wish to override these values' >>site.tmp - @echo '# edit the last section' >>site.tmp - @echo 'set srcdir "$(srcdir)"' >>site.tmp -- @echo "set objdir `pwd`" >>site.tmp -+ @echo "set objdir \"`pwd`\"" >>site.tmp - @echo 'set build_alias "$(build_alias)"' >>site.tmp - @echo 'set build_triplet $(build_triplet)' >>site.tmp - @echo 'set host_alias "$(host_alias)"' >>site.tmp -diff -ur libffi-3.3/testsuite/libffi.closures/huge_struct.c libffi-3.3.new/testsuite/libffi.closures/huge_struct.c ---- libffi-3.3/testsuite/libffi.closures/huge_struct.c 2019-11-19 08:06:49.000000000 -0700 -+++ libffi-3.3.new/testsuite/libffi.closures/huge_struct.c 2021-01-04 19:39:02.000000000 -0700 -@@ -9,6 +9,8 @@ - /* { dg-options -mlong-double-128 { target powerpc64*-*-linux* } } */ - /* { dg-options -Wformat=0 { target moxie*-*-elf or1k-*-* } } */ - -+#include -+ - #include "ffitest.h" - - typedef struct BigStruct{ diff --git a/omnibus/config/patches/m4/m4-1.4.18-glibc-change-work-around.patch b/omnibus/config/patches/m4/m4-1.4.18-glibc-change-work-around.patch deleted file mode 100644 index 582ae9b53..000000000 --- a/omnibus/config/patches/m4/m4-1.4.18-glibc-change-work-around.patch +++ /dev/null @@ -1,115 +0,0 @@ -diff -up m4-1.4.18/lib/fflush.c.orig m4-1.4.18/lib/fflush.c ---- m4-1.4.18/lib/fflush.c.orig 2018-05-02 12:35:59.536851666 +0200 -+++ m4-1.4.18/lib/fflush.c 2018-05-02 12:37:02.768958606 +0200 -@@ -33,7 +33,7 @@ - #undef fflush - - --#if defined _IO_ftrylockfile || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */ -+#if defined _IO_EOF_SEEN || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */ - - /* Clear the stream's ungetc buffer, preserving the value of ftello (fp). */ - static void -@@ -72,7 +72,7 @@ clear_ungetc_buffer (FILE *fp) - - #endif - --#if ! (defined _IO_ftrylockfile || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */) -+#if ! (defined _IO_EOF_SEEN || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */) - - # if (defined __sferror || defined __DragonFly__ || defined __ANDROID__) && defined __SNPT - /* FreeBSD, NetBSD, OpenBSD, DragonFly, Mac OS X, Cygwin, Android */ -@@ -148,7 +148,7 @@ rpl_fflush (FILE *stream) - if (stream == NULL || ! freading (stream)) - return fflush (stream); - --#if defined _IO_ftrylockfile || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */ -+#if defined _IO_EOF_SEEN || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */ - - clear_ungetc_buffer_preserving_position (stream); - -diff -up m4-1.4.18/lib/fpending.c.orig m4-1.4.18/lib/fpending.c ---- m4-1.4.18/lib/fpending.c.orig 2018-05-02 12:35:32.305806774 +0200 -+++ m4-1.4.18/lib/fpending.c 2018-05-02 12:35:44.944827347 +0200 -@@ -32,7 +32,7 @@ __fpending (FILE *fp) - /* Most systems provide FILE as a struct and the necessary bitmask in - , because they need it for implementing getc() and putc() as - fast macros. */ --#if defined _IO_ftrylockfile || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */ -+#if defined _IO_EOF_SEEN || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */ - return fp->_IO_write_ptr - fp->_IO_write_base; - #elif defined __sferror || defined __DragonFly__ || defined __ANDROID__ - /* FreeBSD, NetBSD, OpenBSD, DragonFly, Mac OS X, Cygwin, Android */ -diff -up m4-1.4.18/lib/fpurge.c.orig m4-1.4.18/lib/fpurge.c ---- m4-1.4.18/lib/fpurge.c.orig 2018-05-02 12:38:13.586078669 +0200 -+++ m4-1.4.18/lib/fpurge.c 2018-05-02 12:38:38.785121867 +0200 -@@ -62,7 +62,7 @@ fpurge (FILE *fp) - /* Most systems provide FILE as a struct and the necessary bitmask in - , because they need it for implementing getc() and putc() as - fast macros. */ --# if defined _IO_ftrylockfile || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */ -+# if defined _IO_EOF_SEEN || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */ - fp->_IO_read_end = fp->_IO_read_ptr; - fp->_IO_write_ptr = fp->_IO_write_base; - /* Avoid memory leak when there is an active ungetc buffer. */ -diff -up m4-1.4.18/lib/freadahead.c.orig m4-1.4.18/lib/freadahead.c ---- m4-1.4.18/lib/freadahead.c.orig 2016-12-31 14:54:41.000000000 +0100 -+++ m4-1.4.18/lib/freadahead.c 2018-05-02 11:43:19.570336724 +0200 -@@ -25,7 +25,7 @@ - size_t - freadahead (FILE *fp) - { --#if defined _IO_ftrylockfile || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */ -+#if defined _IO_EOF_SEEN || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */ - if (fp->_IO_write_ptr > fp->_IO_write_base) - return 0; - return (fp->_IO_read_end - fp->_IO_read_ptr) -diff -up m4-1.4.18/lib/freading.c.orig m4-1.4.18/lib/freading.c ---- m4-1.4.18/lib/freading.c.orig 2018-05-02 12:37:33.970011368 +0200 -+++ m4-1.4.18/lib/freading.c 2018-05-02 12:37:59.393054359 +0200 -@@ -31,7 +31,7 @@ freading (FILE *fp) - /* Most systems provide FILE as a struct and the necessary bitmask in - , because they need it for implementing getc() and putc() as - fast macros. */ --# if defined _IO_ftrylockfile || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */ -+# if defined _IO_EOF_SEEN || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */ - return ((fp->_flags & _IO_NO_WRITES) != 0 - || ((fp->_flags & (_IO_NO_READS | _IO_CURRENTLY_PUTTING)) == 0 - && fp->_IO_read_base != NULL)); -diff -up m4-1.4.18/lib/fseeko.c.orig m4-1.4.18/lib/fseeko.c ---- m4-1.4.18/lib/fseeko.c.orig 2018-05-02 11:44:17.947460233 +0200 -+++ m4-1.4.18/lib/fseeko.c 2018-05-02 12:39:49.537216897 +0200 -@@ -47,7 +47,7 @@ fseeko (FILE *fp, off_t offset, int when - #endif - - /* These tests are based on fpurge.c. */ --#if defined _IO_ftrylockfile || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */ -+#if defined _IO_EOF_SEEN || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */ - if (fp->_IO_read_end == fp->_IO_read_ptr - && fp->_IO_write_ptr == fp->_IO_write_base - && fp->_IO_save_base == NULL) -@@ -123,7 +123,7 @@ fseeko (FILE *fp, off_t offset, int when - return -1; - } - --#if defined _IO_ftrylockfile || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */ -+#if defined _IO_EOF_SEEN || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */ - fp->_flags &= ~_IO_EOF_SEEN; - fp->_offset = pos; - #elif defined __sferror || defined __DragonFly__ || defined __ANDROID__ -diff -up m4-1.4.18/lib/stdio-impl.h.orig m4-1.4.18/lib/stdio-impl.h ---- m4-1.4.18/lib/stdio-impl.h.orig 2016-12-31 14:54:42.000000000 +0100 -+++ m4-1.4.18/lib/stdio-impl.h 2018-05-02 11:43:19.570336724 +0200 -@@ -18,6 +18,12 @@ - the same implementation of stdio extension API, except that some fields - have different naming conventions, or their access requires some casts. */ - -+/* Glibc 2.28 made _IO_IN_BACKUP private. For now, work around this -+ problem by defining it ourselves. FIXME: Do not rely on glibc -+ internals. */ -+#if !defined _IO_IN_BACKUP && defined _IO_EOF_SEEN -+# define _IO_IN_BACKUP 0x100 -+#endif - - /* BSD stdio derived implementations. */ - diff --git a/omnibus/config/patches/ncurses/ncurses-5.9-gcc-5.patch b/omnibus/config/patches/ncurses/ncurses-5.9-gcc-5.patch deleted file mode 100644 index ddfbf30a7..000000000 --- a/omnibus/config/patches/ncurses/ncurses-5.9-gcc-5.patch +++ /dev/null @@ -1,46 +0,0 @@ -https://bugs.gentoo.org/545114 - -extracted from the upstream change (which had many unrelated commits in one) - -From 97bb4678dc03e753290b39bbff30ba2825df9517 Mon Sep 17 00:00:00 2001 -From: "Thomas E. Dickey" -Date: Sun, 7 Dec 2014 03:10:09 +0000 -Subject: [PATCH] ncurses 5.9 - patch 20141206 - -+ modify MKlib_gen.sh to work around change in development version of - gcc introduced here: - https://gcc.gnu.org/ml/gcc-patches/2014-06/msg02185.html - https://gcc.gnu.org/ml/gcc-patches/2014-07/msg00236.html - (reports by Marcus Shawcroft, Maohui Lei). - -diff --git a/ncurses/base/MKlib_gen.sh b/ncurses/base/MKlib_gen.sh -index d8cc3c9..b91398c 100755 ---- a/ncurses/base/MKlib_gen.sh -+++ b/ncurses/base/MKlib_gen.sh -@@ -474,11 +474,22 @@ sed -n -f $ED1 \ - -e 's/gen_$//' \ - -e 's/ / /g' >>$TMP - -+cat >$ED1 < $ED2 -+cat $ED2 >$TMP -+ - $preprocessor $TMP 2>/dev/null \ --| sed \ -- -e 's/ / /g' \ -- -e 's/^ //' \ -- -e 's/_Bool/NCURSES_BOOL/g' \ -+| sed -f $ED1 \ - | $AWK -f $AW2 \ - | sed -f $ED3 \ - | sed \ diff --git a/omnibus/config/patches/ncurses/ncurses-5.9-solaris-xopen_source_extended-detection.patch b/omnibus/config/patches/ncurses/ncurses-5.9-solaris-xopen_source_extended-detection.patch deleted file mode 100644 index 270c02a19..000000000 --- a/omnibus/config/patches/ncurses/ncurses-5.9-solaris-xopen_source_extended-detection.patch +++ /dev/null @@ -1,11 +0,0 @@ ---- configure.after.pkgin.patches 2012-12-17 01:06:16.964187316 +0000 -+++ configure 2012-12-17 01:07:17.046932230 +0000 -@@ -7864,7 +7864,7 @@ - else - echo "$as_me: failed program was:" >&5 - cat conftest.$ac_ext >&5 --cf_result=yes -+cf_result=no - fi - rm -f conftest.$ac_objext conftest.$ac_ext - echo "$as_me:7863: result: $cf_result" >&5 diff --git a/omnibus/config/patches/ncurses/ncurses-clang.patch b/omnibus/config/patches/ncurses/ncurses-clang.patch deleted file mode 100644 index 30e0f216d..000000000 --- a/omnibus/config/patches/ncurses/ncurses-clang.patch +++ /dev/null @@ -1,42 +0,0 @@ -diff -ruNp ncurses-5.9.orig/c++/cursesf.h ncurses-5.9/c++/cursesf.h ---- ncurses-5.9.orig/c++/cursesf.h 2005-08-13 21:08:24.000000000 +0300 -+++ ncurses-5.9/c++/cursesf.h 2011-04-03 18:29:29.000000000 +0300 -@@ -681,7 +681,7 @@ public: - const T* p_UserData = STATIC_CAST(T*)(0), - bool with_frame=FALSE, - bool autoDelete_Fields=FALSE) -- : NCursesForm (Fields, with_frame, autoDelete_Fields) { -+ : NCursesForm (&Fields, with_frame, autoDelete_Fields) { - if (form) - set_user (const_cast(p_UserData)); - }; -@@ -694,7 +694,7 @@ public: - const T* p_UserData = STATIC_CAST(T*)(0), - bool with_frame=FALSE, - bool autoDelete_Fields=FALSE) -- : NCursesForm (Fields, nlines, ncols, begin_y, begin_x, -+ : NCursesForm (&Fields, nlines, ncols, begin_y, begin_x, - with_frame, autoDelete_Fields) { - if (form) - set_user (const_cast(p_UserData)); -diff -ruNp ncurses-5.9.orig/c++/cursesm.h ncurses-5.9/c++/cursesm.h ---- ncurses-5.9.orig/c++/cursesm.h 2005-08-13 21:10:36.000000000 +0300 -+++ ncurses-5.9/c++/cursesm.h 2011-04-03 18:31:42.000000000 +0300 -@@ -639,7 +639,7 @@ public: - const T* p_UserData = STATIC_CAST(T*)(0), - bool with_frame=FALSE, - bool autoDelete_Items=FALSE) -- : NCursesMenu (Items, with_frame, autoDelete_Items) { -+ : NCursesMenu (&Items, with_frame, autoDelete_Items) { - if (menu) - set_user (const_cast(p_UserData)); - }; -@@ -651,7 +651,7 @@ public: - int begin_x = 0, - const T* p_UserData = STATIC_CAST(T*)(0), - bool with_frame=FALSE) -- : NCursesMenu (Items, nlines, ncols, begin_y, begin_x, with_frame) { -+ : NCursesMenu (&Items, nlines, ncols, begin_y, begin_x, with_frame) { - if (menu) - set_user (const_cast(p_UserData)); - }; diff --git a/omnibus/config/patches/ncurses/patch-aa b/omnibus/config/patches/ncurses/patch-aa deleted file mode 100644 index 215921d8c..000000000 --- a/omnibus/config/patches/ncurses/patch-aa +++ /dev/null @@ -1,23 +0,0 @@ -$NetBSD: patch-aa,v 1.16 2011/02/28 11:02:46 adam Exp $ - ---- misc/run_tic.in.orig 2006-10-28 21:43:30.000000000 +0200 -+++ misc/run_tic.in -@@ -122,7 +122,7 @@ TICDIR=`echo $TERMINFO | sed -e 's%/shar - # would generate a lot of confusing error messages if we tried to overwrite it. - # We explicitly remove its contents rather than the directory itself, in case - # the directory is actually a symbolic link. --( test -d "$TERMINFO" && cd $TERMINFO && rm -fr ? 2>/dev/null ) -+#( test -d "$TERMINFO" && cd $TERMINFO && rm -fr ? 2>/dev/null ) - - if test "$ext_funcs" = 1 ; then - cat <&6 - - ### Construct the list of include-directories to be generated - --CPPFLAGS="$CPPFLAGS -I. -I../include" -+CPPFLAGS="-I. -I../include $CPPFLAGS" - if test "$srcdir" != "."; then - CPPFLAGS="$CPPFLAGS -I\${srcdir}/../include" - fi diff --git a/omnibus/config/patches/ncurses/patch-ad b/omnibus/config/patches/ncurses/patch-ad deleted file mode 100644 index 46c758f79..000000000 --- a/omnibus/config/patches/ncurses/patch-ad +++ /dev/null @@ -1,12 +0,0 @@ -$NetBSD: patch-ad,v 1.11 2011/02/28 11:02:46 adam Exp $ - ---- c++/Makefile.in.orig 2010-11-27 21:45:27.000000000 +0000 -+++ c++/Makefile.in -@@ -167,7 +167,7 @@ LIB_OBJS = \ - - ../lib/$(LIBNAME_LIBTOOL) : $(LIB_OBJS) - cd ../lib && $(LIBTOOL_LINK) $(CXX) $(CXXFLAGS) \ -- -o $(LIBNAME) $(LIB_OBJS:$o=.lo) \ -+ -o $(LIBNAME) $(LIB_OBJS:.o=.lo) \ - -rpath $(INSTALL_PREFIX)$(libdir) \ - $(LIBTOOL_VERSION) $(NCURSES_MAJOR):$(NCURSES_MINOR) $(LT_UNDEF) $(SHLIB_LIST) diff --git a/omnibus/config/patches/ncurses/patch-cxx_cursesf.h b/omnibus/config/patches/ncurses/patch-cxx_cursesf.h deleted file mode 100644 index f27c14aff..000000000 --- a/omnibus/config/patches/ncurses/patch-cxx_cursesf.h +++ /dev/null @@ -1,22 +0,0 @@ -$NetBSD: patch-cxx_cursesf.h,v 1.1 2011/02/28 11:02:46 adam Exp $ - ---- c++/cursesf.h.orig 2011-02-28 09:23:33.000000000 +0000 -+++ c++/cursesf.h -@@ -677,7 +677,7 @@ protected: - } - - public: -- NCursesUserForm (NCursesFormField Fields[], -+ NCursesUserForm (NCursesFormField *Fields[], - const T* p_UserData = STATIC_CAST(T*)(0), - bool with_frame=FALSE, - bool autoDelete_Fields=FALSE) -@@ -686,7 +686,7 @@ public: - set_user (const_cast(p_UserData)); - }; - -- NCursesUserForm (NCursesFormField Fields[], -+ NCursesUserForm (NCursesFormField *Fields[], - int nlines, - int ncols, - int begin_y = 0, diff --git a/omnibus/config/patches/ncurses/patch-cxx_cursesm.h b/omnibus/config/patches/ncurses/patch-cxx_cursesm.h deleted file mode 100644 index 9455082e3..000000000 --- a/omnibus/config/patches/ncurses/patch-cxx_cursesm.h +++ /dev/null @@ -1,22 +0,0 @@ -$NetBSD: patch-cxx_cursesm.h,v 1.1 2011/02/28 11:02:46 adam Exp $ - ---- c++/cursesm.h.orig 2011-02-28 09:25:22.000000000 +0000 -+++ c++/cursesm.h -@@ -635,7 +635,7 @@ protected: - } - - public: -- NCursesUserMenu (NCursesMenuItem Items[], -+ NCursesUserMenu (NCursesMenuItem *Items[], - const T* p_UserData = STATIC_CAST(T*)(0), - bool with_frame=FALSE, - bool autoDelete_Items=FALSE) -@@ -644,7 +644,7 @@ public: - set_user (const_cast(p_UserData)); - }; - -- NCursesUserMenu (NCursesMenuItem Items[], -+ NCursesUserMenu (NCursesMenuItem *Items[], - int nlines, - int ncols, - int begin_y = 0, diff --git a/omnibus/config/patches/ncurses/patch-ncurses_tinfo_lib__baudrate.c b/omnibus/config/patches/ncurses/patch-ncurses_tinfo_lib__baudrate.c deleted file mode 100644 index 766813511..000000000 --- a/omnibus/config/patches/ncurses/patch-ncurses_tinfo_lib__baudrate.c +++ /dev/null @@ -1,24 +0,0 @@ -$NetBSD: patch-ncurses_tinfo_lib__baudrate.c,v 1.1 2014/05/11 16:55:17 rodent Exp $ - -sys/ttydev.h doesn't exist in OpenBSD 5.5 - ---- ncurses/tinfo/lib_baudrate.c.orig Sun Dec 19 01:50:50 2010 -+++ ncurses/tinfo/lib_baudrate.c -@@ -39,7 +39,7 @@ - - #include - #include /* ospeed */ --#if defined(__FreeBSD__) -+#if defined(__FreeBSD__) || defined(__OpenBSD__) - #include - #endif - -@@ -49,7 +49,7 @@ - * of the indices up to B115200 fit nicely in a 'short', allowing us to retain - * ospeed's type for compatibility. - */ --#if (defined(__FreeBSD__) && (__FreeBSD_version < 700000)) || defined(__NetBSD__) || defined(__OpenBSD__) -+#if (defined(__FreeBSD__) && (__FreeBSD_version < 700000)) || defined(__NetBSD__) || (defined(__OpenBSD__) && (OpenBSD < 201405)) - #undef B0 - #undef B50 - #undef B75 diff --git a/omnibus/config/patches/omnibus-ctl/skip-license-acceptance.patch b/omnibus/config/patches/omnibus-ctl/skip-license-acceptance.patch deleted file mode 100644 index 68bf2334c..000000000 --- a/omnibus/config/patches/omnibus-ctl/skip-license-acceptance.patch +++ /dev/null @@ -1,12 +0,0 @@ -diff --git a/lib/omnibus-ctl.rb b/lib/omnibus-ctl.rb -index b3e06c2..acbf8b9 100644 ---- a/lib/omnibus-ctl.rb -+++ b/lib/omnibus-ctl.rb -@@ -504,7 +504,6 @@ EOM - # args being passed to this command does not include the ones that are - # starting with "-". See #is_option? method. If it is starting with "-" - # then it is treated as a option and we need to look for them in ARGV. -- check_license_acceptance(ARGV.include?("--accept-license")) - - status = run_chef("#{base_path}/embedded/cookbooks/dna.json") - if status.success? diff --git a/omnibus/config/patches/openssl/openssl-1.0.1f-do-not-build-docs.patch b/omnibus/config/patches/openssl/openssl-1.0.1f-do-not-build-docs.patch deleted file mode 100644 index 9162cd9c1..000000000 --- a/omnibus/config/patches/openssl/openssl-1.0.1f-do-not-build-docs.patch +++ /dev/null @@ -1,28 +0,0 @@ ---- openssl-1.0.1f/Makefile.org.orig 2014-01-08 10:58:40.000000000 -0800 -+++ openssl-1.0.1f/Makefile.org 2014-01-08 11:06:29.000000000 -0800 -@@ -167,7 +167,7 @@ - - TOP= . - ONEDIRS=out tmp --EDIRS= times doc bugs util include certs ms shlib mt demos perl sf dep VMS -+EDIRS= times bugs util include certs ms shlib mt demos perl sf dep VMS - WDIRS= windows - LIBS= libcrypto.a libssl.a - SHARED_CRYPTO=libcrypto$(SHLIB_EXT) -@@ -538,7 +538,7 @@ - dist_pem_h: - (cd crypto/pem; $(MAKE) -e $(BUILDENV) pem.h; $(MAKE) clean) - --install: all install_docs install_sw -+install: all install_sw - - install_sw: - @$(PERL) $(TOP)/util/mkdir-p.pl $(INSTALL_PREFIX)$(INSTALLTOP)/bin \ -@@ -603,7 +603,6 @@ - echo 'OpenSSL shared libraries have been installed in:'; \ - echo ' $(INSTALLTOP)'; \ - echo ''; \ -- sed -e '1,/^$$/d' doc/openssl-shared.txt; \ - fi; \ - fi - cp libcrypto.pc $(INSTALL_PREFIX)$(INSTALLTOP)/$(LIBDIR)/pkgconfig diff --git a/omnibus/config/patches/openssl/openssl-1.0.1j-windows-relocate-dll.patch b/omnibus/config/patches/openssl/openssl-1.0.1j-windows-relocate-dll.patch deleted file mode 100644 index 96e6efc9a..000000000 --- a/omnibus/config/patches/openssl/openssl-1.0.1j-windows-relocate-dll.patch +++ /dev/null @@ -1,20 +0,0 @@ -diff --git a/Makefile.shared b/Makefile.shared -index e8d222a..02ec85b 100644 ---- a/Makefile.shared -+++ b/Makefile.shared -@@ -283,13 +283,12 @@ link_a.cygwin: - base=-Wl,--enable-auto-image-base; \ - if expr $(PLATFORM) : 'mingw' > /dev/null; then \ - case $(LIBNAME) in \ -- crypto) SHLIB=libeay;; \ -- ssl) SHLIB=ssleay;; \ -+ crypto) SHLIB=libeay; base=-Wl,--image-base,0x64000000;; \ -+ ssl) SHLIB=ssleay; base=-Wl,--image-base,0x65000000;; \ - esac; \ - SHLIB_SOVER=32; \ - extras="$(LIBNAME).def"; \ - $(PERL) util/mkdef.pl 32 $$SHLIB > $$extras; \ -- base=; [ $(LIBNAME) = "crypto" -a -n "$(FIPSCANLIB)" ] && base=-Wl,--image-base,0x63000000; \ - fi; \ - dll_name=$$SHLIB$$SHLIB_SOVER$$SHLIB_SUFFIX; \ - $(PERL) util/mkrc.pl $$dll_name | \ diff --git a/omnibus/config/patches/openssl/openssl-1.0.1q-fix-compiler-flags-table-for-msys.patch b/omnibus/config/patches/openssl/openssl-1.0.1q-fix-compiler-flags-table-for-msys.patch deleted file mode 100644 index d205cd6b2..000000000 --- a/omnibus/config/patches/openssl/openssl-1.0.1q-fix-compiler-flags-table-for-msys.patch +++ /dev/null @@ -1,20 +0,0 @@ ---- openssl-1.0.1q/Configure.orig 2015-12-15 17:47:52.000000000 -0500 -+++ openssl-1.0.1q/Configure 2015-12-15 18:31:01.000000000 -0500 -@@ -537,7 +537,7 @@ - "BC-32","bcc32::::WIN32::BN_LLONG DES_PTR RC4_INDEX EXPORT_VAR_AS_FN:${no_asm}:win32", - - # MinGW --"mingw", "gcc:-mno-cygwin -DL_ENDIAN -DWIN32_LEAN_AND_MEAN -fomit-frame-pointer -O3 -march=i486 -Wall::-D_MT:MINGW32:-lws2_32 -lgdi32 -lcrypt32:BN_LLONG ${x86_gcc_des} ${x86_gcc_opts} EXPORT_VAR_AS_FN:${x86_asm}:coff:win32:cygwin-shared:-D_WINDLL -DOPENSSL_USE_APPLINK:-mno-cygwin:.dll.a", -+"mingw", "gcc:-mno-cygwin -DL_ENDIAN -DWIN32_LEAN_AND_MEAN -fomit-frame-pointer -O3 -march=i486 -Wall::-D_MT:MINGW32:-lws2_32 -lgdi32 -lcrypt32:BN_LLONG ${x86_gcc_des} ${x86_gcc_opts} EXPORT_VAR_AS_FN:${x86_asm}:coff:win32:cygwin-shared:-D_WINDLL:-mno-cygwin:.dll.a", - # As for OPENSSL_USE_APPLINK. Applink makes it possible to use .dll - # compiled with one compiler with application compiled with another - # compiler. It's possible to engage Applink support in mingw64 build, -@@ -545,7 +545,7 @@ - # handling, one can't seriously consider its binaries for using with - # non-mingw64 run-time environment. And as mingw64 is always consistent - # with itself, Applink is never engaged and can as well be omitted. --"mingw64", "gcc:-mno-cygwin -DL_ENDIAN -O3 -Wall -DWIN32_LEAN_AND_MEAN -DUNICODE -D_UNICODE::-D_MT:MINGW64:-lws2_32 -lgdi32 -lcrypt32:SIXTY_FOUR_BIT RC4_CHUNK_LL DES_INT EXPORT_VAR_AS_FN:${x86_64_asm}:mingw64:win32:cygwin-shared:-D_WINDLL:-mno-cygwin:.dll.a", -+"mingw64", "gcc:-mno-cygwin -DL_ENDIAN -O3 -Wall -DWIN32_LEAN_AND_MEAN -DUNICODE -D_UNICODE::-D_MT:MINGW64:-lws2_32 -lgdi32 -lcrypt32:SIXTY_FOUR_BIT RC4_CHUNK_LL DES_INT EXPORT_VAR_AS_FN:${x86_64_asm}:mingw64:win32:cygwin-shared:-D_WINDLL:-mno-cygwin:.dll.a", - - # UWIN - "UWIN", "cc:-DTERMIOS -DL_ENDIAN -O -Wall:::UWIN::BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:${no_asm}:win32", diff --git a/omnibus/config/patches/openssl/openssl-1.0.2x-darwin-arm64.patch b/omnibus/config/patches/openssl/openssl-1.0.2x-darwin-arm64.patch deleted file mode 100644 index 7c245e011..000000000 --- a/omnibus/config/patches/openssl/openssl-1.0.2x-darwin-arm64.patch +++ /dev/null @@ -1,54 +0,0 @@ -diff -ur openssl-1.0.2x/Configure openssl-1.0.2x.new/Configure ---- openssl-1.0.2x/Configure 2020-12-08 13:23:12.000000000 +0000 -+++ openssl-1.0.2x.new/Configure 2021-01-12 08:24:27.000000000 +0000 -@@ -156,6 +156,7 @@ - - my $x86_elf_asm="$x86_asm:elf"; - -+my $arm64_asm="arm64cpuid.o:arm64-gcc.o arm64-mont.o arm64-mont5.o arm64-gf2m.o modexp512-arm64.o::aes-arm64.o vpaes-arm64.o bsaes-arm64.o aesni-arm64.o aesni-sha1-arm64.o::md5-arm64.o:sha1-arm64.o sha256-arm64.o sha512-arm64.o::rc4-arm64.o rc4-md5-arm64.o:::wp-arm64.o:cmll-arm64.o cmll_misc.o:ghash-arm64.o:"; - my $x86_64_asm="x86_64cpuid.o:x86_64-gcc.o x86_64-mont.o x86_64-mont5.o x86_64-gf2m.o rsaz_exp.o rsaz-x86_64.o rsaz-avx2.o:ecp_nistz256.o ecp_nistz256-x86_64.o::aes-x86_64.o vpaes-x86_64.o bsaes-x86_64.o aesni-x86_64.o aesni-sha1-x86_64.o aesni-sha256-x86_64.o aesni-mb-x86_64.o::md5-x86_64.o:sha1-x86_64.o sha256-x86_64.o sha512-x86_64.o sha1-mb-x86_64.o sha256-mb-x86_64.o::rc4-x86_64.o rc4-md5-x86_64.o:::wp-x86_64.o:cmll-x86_64.o cmll_misc.o:ghash-x86_64.o aesni-gcm-x86_64.o:"; - my $ia64_asm="ia64cpuid.o:bn-ia64.o ia64-mont.o:::aes_core.o aes_cbc.o aes-ia64.o::md5-ia64.o:sha1-ia64.o sha256-ia64.o sha512-ia64.o::rc4-ia64.o rc4_skey.o:::::ghash-ia64.o::void"; - my $sparcv9_asm="sparcv9cap.o sparccpuid.o:bn-sparcv9.o sparcv9-mont.o sparcv9a-mont.o vis3-mont.o sparct4-mont.o sparcv9-gf2m.o::des_enc-sparc.o fcrypt_b.o dest4-sparcv9.o:aes_core.o aes_cbc.o aes-sparcv9.o aest4-sparcv9.o::md5-sparcv9.o:sha1-sparcv9.o sha256-sparcv9.o sha512-sparcv9.o::::::camellia.o cmll_misc.o cmll_cbc.o cmllt4-sparcv9.o:ghash-sparcv9.o::void"; -@@ -649,6 +650,7 @@ - "darwin64-ppc-cc","cc:-arch ppc64 -O3 -DB_ENDIAN::-D_REENTRANT:MACOSX:-Wl,-search_paths_first%:SIXTY_FOUR_BIT_LONG RC4_CHAR RC4_CHUNK DES_UNROLL BF_PTR:${ppc64_asm}:osx64:dlfcn:darwin-shared:-fPIC -fno-common:-arch ppc64 -dynamiclib:.\$(SHLIB_MAJOR).\$(SHLIB_MINOR).dylib", - "darwin-i386-cc","cc:-arch i386 -O3 -fomit-frame-pointer -DL_ENDIAN::-D_REENTRANT:MACOSX:-Wl,-search_paths_first%:BN_LLONG RC4_INT RC4_CHUNK DES_UNROLL BF_PTR:".eval{my $asm=$x86_asm;$asm=~s/cast\-586\.o//;$asm}.":macosx:dlfcn:darwin-shared:-fPIC -fno-common:-arch i386 -dynamiclib:.\$(SHLIB_MAJOR).\$(SHLIB_MINOR).dylib", - "debug-darwin-i386-cc","cc:-arch i386 -g3 -DL_ENDIAN::-D_REENTRANT:MACOSX:-Wl,-search_paths_first%:BN_LLONG RC4_INT RC4_CHUNK DES_UNROLL BF_PTR:${x86_asm}:macosx:dlfcn:darwin-shared:-fPIC -fno-common:-arch i386 -dynamiclib:.\$(SHLIB_MAJOR).\$(SHLIB_MINOR).dylib", -+"darwin64-arm64-cc","cc:-arch arm64 -O3 -DL_ENDIAN -Wall::-D_REENTRANT:MACOSX:-Wl,-search_paths_first%:SIXTY_FOUR_BIT_LONG RC4_CHAR RC4_CHUNK DES_INT DES_UNROLL:".eval{my $asm=$arm64_asm;$asm=~s/rc4\-[^:]+//;$asm}.":macosx:dlfcn:darwin-shared:-fPIC -fno-common:-arch arm64 -dynamiclib:.\$(SHLIB_MAJOR).\$(SHLIB_MINOR).dylib", - "darwin64-x86_64-cc","cc:-arch x86_64 -O3 -DL_ENDIAN -Wall::-D_REENTRANT:MACOSX:-Wl,-search_paths_first%:SIXTY_FOUR_BIT_LONG RC4_CHUNK DES_INT DES_UNROLL:".eval{my $asm=$x86_64_asm;$asm=~s/rc4\-[^:]+//;$asm}.":macosx:dlfcn:darwin-shared:-fPIC -fno-common:-arch x86_64 -dynamiclib:.\$(SHLIB_MAJOR).\$(SHLIB_MINOR).dylib", - "debug-darwin64-x86_64-cc","cc:-arch x86_64 -ggdb -g2 -O0 -DL_ENDIAN -Wall::-D_REENTRANT:MACOSX:-Wl,-search_paths_first%:SIXTY_FOUR_BIT_LONG RC4_CHUNK DES_INT DES_UNROLL:".eval{my $asm=$x86_64_asm;$asm=~s/rc4\-[^:]+//;$asm}.":macosx:dlfcn:darwin-shared:-fPIC -fno-common:-arch x86_64 -dynamiclib:.\$(SHLIB_MAJOR).\$(SHLIB_MINOR).dylib", - "debug-darwin-ppc-cc","cc:-DBN_DEBUG -DREF_CHECK -DCONF_DEBUG -DCRYPTO_MDEBUG -DB_ENDIAN -g -Wall -O::-D_REENTRANT:MACOSX::BN_LLONG RC4_CHAR RC4_CHUNK DES_UNROLL BF_PTR:${ppc32_asm}:osx32:dlfcn:darwin-shared:-fPIC:-dynamiclib:.\$(SHLIB_MAJOR).\$(SHLIB_MINOR).dylib", -diff -ur openssl-1.0.2x/config openssl-1.0.2x.new/config ---- openssl-1.0.2x/config 2020-12-08 13:23:12.000000000 +0000 -+++ openssl-1.0.2x.new/config 2021-01-12 08:39:17.000000000 +0000 -@@ -274,6 +274,9 @@ - - Darwin:*) - case "$MACHINE" in -+ arm*) -+ echo "arm-apple-darwin${VERSION}" -+ ;; - Power*) - echo "ppc-apple-darwin${VERSION}" - ;; -@@ -560,6 +563,21 @@ - else - OUT="darwin-ppc-cc" - fi ;; -+ arm-apple-darwin*) -+ ISA64=`(sysctl -n hw.optional.arm64) 2>/dev/null` -+ if [ "$ISA64" = "1" -a -z "$KERNEL_BITS" ]; then -+ echo "WARNING! If you wish to build M1 ARM 64-bit library, then you have to" -+ echo " invoke './Configure darwin64-arm64-cc' *manually*." -+ if [ "$TEST" = "false" -a -t 1 ]; then -+ echo " You have about 5 seconds to press Ctrl-C to abort." -+ (trap "stty `stty -g`" 2 0; stty -icanon min 0 time 50; read waste) <&1 -+ fi -+ fi -+ if [ "$ISA64" = "1" -a "$KERNEL_BITS" = "64" ]; then -+ OUT="darwin64-arm64-cc" -+ else -+ OUT="darwin-arm64-cc" -+ fi ;; - i?86-apple-darwin*) - ISA64=`(sysctl -n hw.optional.x86_64) 2>/dev/null` - if [ "$ISA64" = "1" -a -z "$KERNEL_BITS" ]; then diff --git a/omnibus/config/patches/openssl/openssl-1.1.0f-do-not-install-docs.patch b/omnibus/config/patches/openssl/openssl-1.1.0f-do-not-install-docs.patch deleted file mode 100644 index 4cb140613..000000000 --- a/omnibus/config/patches/openssl/openssl-1.1.0f-do-not-install-docs.patch +++ /dev/null @@ -1,10 +0,0 @@ ---- openssl-1.1.0f/Configurations/unix-Makefile.tmpl.orig 2017-10-22 13:23:48.592533617 +0300 -+++ openssl-1.1.0f/Configurations/unix-Makefile.tmpl 2017-10-22 13:26:21.199065333 +0300 -@@ -260,7 +260,7 @@ - @echo "Tests are not supported with your chosen Configure options" - @ : {- output_on() if !$disabled{tests}; "" -} - --install: install_sw install_ssldirs install_docs -+install: install_sw install_ssldirs - - uninstall: uninstall_docs uninstall_sw diff --git a/omnibus/config/patches/perl/perl-5.18.1-remove_lnsl.patch b/omnibus/config/patches/perl/perl-5.18.1-remove_lnsl.patch deleted file mode 100644 index 6cf59a718..000000000 --- a/omnibus/config/patches/perl/perl-5.18.1-remove_lnsl.patch +++ /dev/null @@ -1,441 +0,0 @@ -diff -ru perl-5.18.1.orig/Configure perl-5.18.1/Configure ---- perl-5.18.1.orig/Configure 2013-08-11 20:44:47.000000000 -0600 -+++ perl-5.18.1/Configure 2019-08-21 09:07:10.876345427 -0600 -@@ -1381,7 +1381,7 @@ - : set usesocks on the Configure command line to enable socks. - : List of libraries we want. - : If anyone needs extra -lxxx, put those in a hint file. --libswanted="sfio socket bind inet nsl nm ndbm gdbm dbm db malloc dl dld ld sun" -+libswanted="sfio socket bind inet nm ndbm gdbm dbm db malloc dl dld ld sun" - libswanted="$libswanted m crypt sec util c cposix posix ucb bsd BSD" - : We probably want to search /usr/shlib before most other libraries. - : This is only used by the lib/ExtUtils/MakeMaker.pm routine extliblist. -diff -ru perl-5.18.1.orig/configure.com perl-5.18.1/configure.com ---- perl-5.18.1.orig/configure.com 2013-08-11 20:44:47.000000000 -0600 -+++ perl-5.18.1/configure.com 2019-08-21 09:07:10.878345427 -0600 -@@ -121,7 +121,7 @@ - $!: full support for void wanted by default !sfn - $!defvoidused=15 !sfn - $!: List of libraries we want. !sfn --$!libswanted='net socket inet nsl nm ndbm gdbm dbm db malloc dl' !sfn -+$!libswanted='net socket inet nm ndbm gdbm dbm db malloc dl' !sfn - $!libswanted="$libswanted dld ld sun m c cposix posix ndir dir crypt" !sfn - $!libswanted="$libswanted ucb bsd BSD PW x" !sfn - $!: We probably want to search /usr/shlib before most other libraries. !sfn -diff -ru perl-5.18.1.orig/cpan/Config-Perl-V/t/20_plv.t perl-5.18.1/cpan/Config-Perl-V/t/20_plv.t ---- perl-5.18.1.orig/cpan/Config-Perl-V/t/20_plv.t 2013-08-11 20:44:47.000000000 -0600 -+++ perl-5.18.1/cpan/Config-Perl-V/t/20_plv.t 2019-08-21 09:07:10.879345427 -0600 -@@ -48,8 +48,8 @@ - Linker and Libraries: - ld='cc', ldflags ='-L/pro/local/lib' - libpth=/pro/local/lib /lib /usr/lib /usr/local/lib -- libs=-lnsl -lgdbm -ldb -ldl -lm -lcrypt -lutil -lc -- perllibs=-lnsl -ldl -lm -lcrypt -lutil -lc -+ libs=-lgdbm -ldb -ldl -lm -lcrypt -lutil -lc -+ perllibs=-ldl -lm -lcrypt -lutil -lc - libc=/lib/libc-2.6.1.so, so=so, useshrplib=false, libperl=libperl.a - gnulibc_version='2.6.1' - Dynamic Linking: -diff -ru perl-5.18.1.orig/Cross/config.sh-arm-linux perl-5.18.1/Cross/config.sh-arm-linux ---- perl-5.18.1.orig/Cross/config.sh-arm-linux 2013-08-11 20:44:47.000000000 -0600 -+++ perl-5.18.1/Cross/config.sh-arm-linux 2019-08-21 09:08:35.251345202 -0600 -@@ -777,12 +777,12 @@ - libc='/lib/libc-2.2.2.so' - libperl='libperl.so' - libpth='/usr/local/lib /lib /usr/lib' --libs='-lnsl -ldl -lm -lcrypt -lutil -lc' -+libs='-ldl -lm -lcrypt -lutil -lc' - libsdirs=' /usr/lib' --libsfiles=' libnsl.so libdl.so libm.so libcrypt.so libutil.so libc.so' --libsfound=' /usr/lib/libnsl.so /usr/lib/libdl.so /usr/lib/libm.so /usr/lib/libcrypt.so /usr/lib/libutil.so /usr/lib/libc.so' -+libsfiles=' libdl.so libm.so libcrypt.so libutil.so libc.so' -+libsfound=' /usr/lib/libdl.so /usr/lib/libm.so /usr/lib/libcrypt.so /usr/lib/libutil.so /usr/lib/libc.so' - libspath=' /usr/local/lib /lib /usr/lib' --libswanted='sfio socket bind inet nsl nm ndbm gdbm dbm db malloc dl dld ld sun m crypt sec util c cposix posix ucb BSD' -+libswanted='sfio socket bind inet nm ndbm gdbm dbm db malloc dl dld ld sun m crypt sec util c cposix posix ucb BSD' - libswanted_uselargefiles='' - line='' - lint='' -@@ -865,7 +865,7 @@ - perl_patchlevel='' - perl_static_inline='static' - perladmin='red@criticalintegration.com' --perllibs='-lnsl -ldl -lm -lcrypt -lutil -lc' -+perllibs='-ldl -lm -lcrypt -lutil -lc' - perlpath='/usr/bin/perl' - pg='pg' - phostname='hostname' -diff -ru perl-5.18.1.orig/Cross/config.sh-arm-linux-n770 perl-5.18.1/Cross/config.sh-arm-linux-n770 ---- perl-5.18.1.orig/Cross/config.sh-arm-linux-n770 2013-08-11 20:44:47.000000000 -0600 -+++ perl-5.18.1/Cross/config.sh-arm-linux-n770 2019-08-21 09:08:35.252345202 -0600 -@@ -748,12 +748,12 @@ - libc='/lib/libc-2.2.2.so' - libperl='libperl.arma' - libpth='/usr/local/lib /lib /usr/lib' --libs='-lnsl -ldl -lm -lcrypt -lutil -lc' -+libs='-ldl -lm -lcrypt -lutil -lc' - libsdirs=' /usr/lib' --libsfiles=' libnsl.so libdl.so libm.so libcrypt.so libutil.so libc.so' --libsfound=' /usr/lib/libnsl.so /usr/lib/libdl.so /usr/lib/libm.so /usr/lib/libcrypt.so /usr/lib/libutil.so /usr/lib/libc.so' -+libsfiles=' libdl.so libm.so libcrypt.so libutil.so libc.so' -+libsfound=' /usr/lib/libdl.so /usr/lib/libm.so /usr/lib/libcrypt.so /usr/lib/libutil.so /usr/lib/libc.so' - libspath=' /usr/local/lib /lib /usr/lib' --libswanted='sfio socket bind inet nsl nm ndbm gdbm dbm db malloc dl dld ld sun m crypt sec util c cposix posix ucb BSD' -+libswanted='sfio socket bind inet nm ndbm gdbm dbm db malloc dl dld ld sun m crypt sec util c cposix posix ucb BSD' - libswanted_uselargefiles='' - line='' - lint='' -@@ -835,7 +835,7 @@ - perl='' - perl_patchlevel='' - perladmin='red@criticalintegration.com' --perllibs='-lnsl -ldl -lm -lcrypt -lutil -lc' -+perllibs='-ldl -lm -lcrypt -lutil -lc' - perlpath='/usr/bin/perl' - pg='pg' - phostname='hostname' -diff -ru perl-5.18.1.orig/hints/aix_4.sh perl-5.18.1/hints/aix_4.sh ---- perl-5.18.1.orig/hints/aix_4.sh 2013-04-30 20:52:55.000000000 -0600 -+++ perl-5.18.1/hints/aix_4.sh 2019-08-21 09:07:10.880345427 -0600 -@@ -583,7 +583,7 @@ - - *** - *** You seem to be compiling in AIX for the OS/400 PASE environment. --*** I'm not going to use the AIX bind, nsl, and possible util libraries, then. -+*** I'm not going to use the AIX bind, and possible util libraries, then. - *** I'm also not going to install perl as /usr/bin/perl. - *** Perl will be installed under $prefix. - *** For instructions how to install this build from AIX to PASE, -@@ -591,7 +591,7 @@ - *** about "Operating system name". - *** - EOF -- set `echo " $libswanted " | sed -e 's@ bind @ @' -e 's@ nsl @ @' -e 's@ util @ @'` -+ set `echo " $libswanted " | sed -e 's@ bind @ @' -e 's@ util @ @'` - shift - libswanted="$*" - installusrbinperl="$undef" -diff -ru perl-5.18.1.orig/hints/aix.sh perl-5.18.1/hints/aix.sh ---- perl-5.18.1.orig/hints/aix.sh 2013-08-11 20:44:48.000000000 -0600 -+++ perl-5.18.1/hints/aix.sh 2019-08-21 09:07:10.880345427 -0600 -@@ -505,7 +505,7 @@ - - *** - *** You seem to be compiling in AIX for the OS/400 PASE environment. --*** I'm not going to use the AIX bind, nsl, and possible util libraries, then. -+*** I'm not going to use the AIX bind, and possible util libraries, then. - *** I'm also not going to install perl as /usr/bin/perl. - *** Perl will be installed under $prefix. - *** For instructions how to install this build from AIX to PASE, -@@ -513,7 +513,7 @@ - *** about "Operating system name". - *** - EOF -- set `echo " $libswanted " | sed -e 's@ bind @ @' -e 's@ nsl @ @' -e 's@ util @ @'` -+ set `echo " $libswanted " | sed -e 's@ bind @ @' -e 's@ util @ @'` - shift - libswanted="$*" - installusrbinperl="$undef" -diff -ru perl-5.18.1.orig/hints/dgux.sh perl-5.18.1/hints/dgux.sh ---- perl-5.18.1.orig/hints/dgux.sh 2013-08-11 20:44:48.000000000 -0600 -+++ perl-5.18.1/hints/dgux.sh 2019-08-21 09:07:10.880345427 -0600 -@@ -154,7 +154,7 @@ - #libswanted="dbm posix $libswanted" - # Do *NOT* add there the malloc native - # DG/UX library! --libswanted="dbm posix resolv socket nsl dl m" -+libswanted="dbm posix resolv socket dl m" - - ##################################### - # -@@ -203,7 +203,7 @@ - # DG/UX's sched_yield is in -lrte - # Do *NOT* add there the malloc native - # DG/UX library! -- libswanted="dbm posix resolv socket nsl dl m rte" -+ libswanted="dbm posix resolv socket dl m rte" - archname="ix86-dgux-thread" - sitearch="$prefix/lib/perl518/$archname" - sitelib="$prefix/lib/perl518" -diff -ru perl-5.18.1.orig/hints/epix.sh perl-5.18.1/hints/epix.sh ---- perl-5.18.1.orig/hints/epix.sh 2013-04-30 20:52:55.000000000 -0600 -+++ perl-5.18.1/hints/epix.sh 2019-08-21 09:07:10.880345427 -0600 -@@ -37,7 +37,7 @@ - # Old version had this, but I'm not sure why since the old version - # also mucked around with libswanted. This is also definitely wrong - # if the user is trying to use DB_File or GDBM_File. --# libs='-lsocket -lnsl -ldbm -ldl -lc -lcrypt -lm -lucb' -+# libs='-lsocket -ldbm -ldl -lc -lcrypt -lm -lucb' - - # We include support for using libraries in /usr/ucblib, but the setting - # of libswanted excludes some libraries found there. You may want to -diff -ru perl-5.18.1.orig/hints/gnu.sh perl-5.18.1/hints/gnu.sh ---- perl-5.18.1.orig/hints/gnu.sh 2013-05-23 17:38:10.000000000 -0600 -+++ perl-5.18.1/hints/gnu.sh 2019-08-21 09:07:10.880345427 -0600 -@@ -4,7 +4,7 @@ - - # libnsl is unusable on the Hurd. - # XXX remove this once SUNRPC is implemented. --set `echo X "$libswanted "| sed -e 's/ nsl / /' -e 's/ c / pthread /'` -+set `echo X "$libswanted "| sed -e 's/ c / pthread /'` - shift - libswanted="$*" - -diff -ru perl-5.18.1.orig/hints/irix_5.sh perl-5.18.1/hints/irix_5.sh ---- perl-5.18.1.orig/hints/irix_5.sh 2013-02-26 14:28:27.000000000 -0700 -+++ perl-5.18.1/hints/irix_5.sh 2019-08-21 09:07:10.881345427 -0600 -@@ -27,9 +27,9 @@ - esac - - lddlflags="-shared" --# For some reason we don't want -lsocket -lnsl or -ldl. Can anyone -+# For some reason we don't want -lsocket or -ldl. Can anyone - # contribute an explanation? --set `echo X "$libswanted "|sed -e 's/ socket / /' -e 's/ nsl / /' -e 's/ dl / /'` -+set `echo X "$libswanted "|sed -e 's/ socket / /' -e 's/ dl / /'` - shift - libswanted="$*" - -diff -ru perl-5.18.1.orig/hints/irix_6_0.sh perl-5.18.1/hints/irix_6_0.sh ---- perl-5.18.1.orig/hints/irix_6_0.sh 2013-02-26 14:28:27.000000000 -0700 -+++ perl-5.18.1/hints/irix_6_0.sh 2019-08-21 09:07:10.881345427 -0600 -@@ -19,7 +19,7 @@ - lddlflags="-32 -shared" - - # We don't want these libraries. Anyone know why? --set `echo X "$libswanted "|sed -e 's/ socket / /' -e 's/ nsl / /' -e 's/ dl / /'` -+set `echo X "$libswanted "|sed -e 's/ socket / /' -e 's/ dl / /'` - shift - libswanted="$*" - # -@@ -29,7 +29,7 @@ - # taken from irix_5.sh . Changes from irix_5.sh: - # Olimit and nested comments (warning 1009) no longer accepted - # -OPT:fold_arith_limit so POSIX module will optimize --# no 64bit versions of sun, crypt, nsl, socket, dl dso's available -+# no 64bit versions of sun, crypt, socket, dl dso's available - # as of IRIX 6.0.1 so omit those from libswanted line via `sed'. - - # perl 5 built with this hints file passes most tests (`make test'). -@@ -38,7 +38,7 @@ - # i_time='define' - # ccflags="$ccflags -D_POSIX_SOURCE -ansiposix -D_BSD_TYPES -woff 1009 -OPT:fold_arith_limit=1046" - # lddlflags="-shared" --# set `echo X "$libswanted "|sed -e 's/ socket / /' -e 's/ sun / /' -e 's/ crypt / /' -e 's/ nsl / /' -e 's/ dl / /'` -+# set `echo X "$libswanted "|sed -e 's/ socket / /' -e 's/ sun / /' -e 's/ crypt / /' -e 's/ dl / /'` - # shift - # libswanted="$*" - -diff -ru perl-5.18.1.orig/hints/irix_6_1.sh perl-5.18.1/hints/irix_6_1.sh ---- perl-5.18.1.orig/hints/irix_6_1.sh 2013-02-26 14:28:27.000000000 -0700 -+++ perl-5.18.1/hints/irix_6_1.sh 2019-08-21 09:07:10.881345427 -0600 -@@ -19,7 +19,7 @@ - lddlflags="-32 -shared" - - # We don't want these libraries. Anyone know why? --set `echo X "$libswanted "|sed -e 's/ socket / /' -e 's/ nsl / /' -e 's/ dl / /'` -+set `echo X "$libswanted "|sed -e 's/ socket / /' -e 's/ dl / /'` - shift - libswanted="$*" - # -@@ -29,7 +29,7 @@ - # taken from irix_5.sh . Changes from irix_5.sh: - # Olimit and nested comments (warning 1009) no longer accepted - # -OPT:fold_arith_limit so POSIX module will optimize --# no 64bit versions of sun, crypt, nsl, socket, dl dso's available -+# no 64bit versions of sun, crypt, socket, dl dso's available - # as of IRIX 6.0.1 so omit those from libswanted line via `sed'. - - # perl 5 built with this hints file passes most tests (`make test'). -@@ -38,7 +38,7 @@ - # i_time='define' - # ccflags="$ccflags -D_POSIX_SOURCE -ansiposix -D_BSD_TYPES -woff 1009 -OPT:fold_arith_limit=1046" - # lddlflags="-shared" --# set `echo X "$libswanted "|sed -e 's/ socket / /' -e 's/ sun / /' -e 's/ crypt / /' -e 's/ nsl / /' -e 's/ dl / /'` -+# set `echo X "$libswanted "|sed -e 's/ socket / /' -e 's/ sun / /' -e 's/ crypt / /' -e 's/ dl / /'` - # shift - # libswanted="$*" - -diff -ru perl-5.18.1.orig/hints/irix_6.sh perl-5.18.1/hints/irix_6.sh ---- perl-5.18.1.orig/hints/irix_6.sh 2013-04-30 20:52:55.000000000 -0600 -+++ perl-5.18.1/hints/irix_6.sh 2019-08-21 09:07:10.881345427 -0600 -@@ -359,7 +359,7 @@ - # Socket networking is in libc, these are not installed by default, - # and just slow perl down. (scotth@sgi.com) - # librt contains nothing we need (some places need it for Time::HiRes) --jhi --set `echo X "$libswanted "|sed -e 's/ socket / /' -e 's/ nsl / /' -e 's/ dl / /' -e 's/ rt / /'` -+set `echo X "$libswanted "|sed -e 's/ socket / /' -e 's/ dl / /' -e 's/ rt / /'` - shift - libswanted="$*" - -diff -ru perl-5.18.1.orig/hints/powerux.sh perl-5.18.1/hints/powerux.sh ---- perl-5.18.1.orig/hints/powerux.sh 2013-04-30 20:52:55.000000000 -0600 -+++ perl-5.18.1/hints/powerux.sh 2019-08-21 09:07:10.882345427 -0600 -@@ -27,11 +27,11 @@ - exit 2 - fi - --# We DO NOT want -lmalloc or -lPW, we DO need -lgen to follow -lnsl, so -+# We DO NOT want -lmalloc or -lPW, we DO need -lgen to follow, so - # fixup libswanted to reflect that desire (also need -lresolv if you want - # DNS name lookup to work, which seems desirable :-). - # --libswanted=`echo ' '$libswanted' ' | sed -e 's/ malloc / /' -e 's/ PW / /' -e 's/ nsl / nsl gen resolv /'` -+libswanted=`echo ' '$libswanted' ' | sed -e 's/ malloc / /' -e 's/ PW / /'` - - # We DO NOT want /usr/ucblib in glibpth - # -diff -ru perl-5.18.1.orig/hints/titanos.sh perl-5.18.1/hints/titanos.sh ---- perl-5.18.1.orig/hints/titanos.sh 2013-02-26 14:28:27.000000000 -0700 -+++ perl-5.18.1/hints/titanos.sh 2019-08-21 09:07:10.882345427 -0600 -@@ -17,14 +17,14 @@ - stdchar='unsigned char' - # - # Apparently there are some harmful libs in Configure's $libswanted. --# Perl5.000 had: libs='-lnsl -ldbm -lPW -lmalloc -lm' -+# Perl5.000 had: libs='-ldbm -lPW -lmalloc -lm' - # Unfortunately, this line prevents users from including things like - # -lgdbm and -ldb, which they may or may not have or want. - # We should probably fiddle with libswanted instead of libs. - # And even there, we should only bother to delete harmful libraries. - # However, I don't know what they are or why they should be deleted, - # so this will have to do for now. --AD 28 Mar 1995 --libswanted='sfio nsl dbm gdbm db PW malloc m' -+libswanted='sfio dbm gdbm db PW malloc m' - # - # Extensions: This system can not compile POSIX. We'll let Configure - # figure out the others. -diff -ru perl-5.18.1.orig/INSTALL perl-5.18.1/INSTALL ---- perl-5.18.1.orig/INSTALL 2013-08-11 20:44:47.000000000 -0600 -+++ perl-5.18.1/INSTALL 2019-08-21 09:07:10.883345427 -0600 -@@ -1583,7 +1583,7 @@ - undefined symbols, check the libs variable in the config.sh file. It - should look something like - -- libs='-lsocket -lnsl -ldl -lm -lc' -+ libs='-lsocket -ldl -lm -lc' - - The exact libraries will vary from system to system, but you typically - need to include at least the math library -lm. Normally, Configure -diff -ru perl-5.18.1.orig/NetWare/config.wc perl-5.18.1/NetWare/config.wc ---- perl-5.18.1.orig/NetWare/config.wc 2013-08-11 20:44:47.000000000 -0600 -+++ perl-5.18.1/NetWare/config.wc 2019-08-21 09:07:10.883345427 -0600 -@@ -757,7 +757,7 @@ - libsfiles='' - libsfound='' - libspath='' --libswanted='net socket inet nsl nm ndbm gdbm dbm db malloc dl dld ld sun m c cposix posix ndir dir crypt ucb bsd BSD PW x' -+libswanted='net socket inet nm ndbm gdbm dbm db malloc dl dld ld sun m c cposix posix ndir dir crypt ucb bsd BSD PW x' - line='line' - lint='' - lkflags='' -diff -ru perl-5.18.1.orig/plan9/config_sh.sample perl-5.18.1/plan9/config_sh.sample ---- perl-5.18.1.orig/plan9/config_sh.sample 2013-08-11 20:44:48.000000000 -0600 -+++ perl-5.18.1/plan9/config_sh.sample 2019-08-21 09:07:10.883345427 -0600 -@@ -764,7 +764,7 @@ - libsfiles='' - libsfound='' - libspath=' /lib' --libswanted='sfio socket bind inet nsl nm ndbm gdbm dbm db malloc dl dld ld sun m c cposix posix ndir dir crypt sec ucb bsd BSD PW x util' -+libswanted='sfio socket bind inet nm ndbm gdbm dbm db malloc dl dld ld sun m c cposix posix ndir dir crypt sec ucb bsd BSD PW x util' - libswanted_uselargefiles='' - line='' - lint='' -diff -ru perl-5.18.1.orig/pod/perlrun.pod perl-5.18.1/pod/perlrun.pod ---- perl-5.18.1.orig/pod/perlrun.pod 2013-08-11 20:44:48.000000000 -0600 -+++ perl-5.18.1/pod/perlrun.pod 2019-08-21 09:07:10.884345427 -0600 -@@ -862,11 +862,11 @@ - $ perl -V:libc - libc='/lib/libc-2.2.4.so'; - $ perl -V:lib. -- libs='-lnsl -lgdbm -ldb -ldl -lm -lcrypt -lutil -lc'; -+ libs='-lgdbm -ldb -ldl -lm -lcrypt -lutil -lc'; - libc='/lib/libc-2.2.4.so'; - $ perl -V:lib.* - libpth='/usr/local/lib /lib /usr/lib'; -- libs='-lnsl -lgdbm -ldb -ldl -lm -lcrypt -lutil -lc'; -+ libs='-lgdbm -ldb -ldl -lm -lcrypt -lutil -lc'; - lib_ext='.a'; - libc='/lib/libc-2.2.4.so'; - libperl='libperl.a'; -diff -ru perl-5.18.1.orig/Porting/bisect-runner.pl perl-5.18.1/Porting/bisect-runner.pl ---- perl-5.18.1.orig/Porting/bisect-runner.pl 2013-08-11 20:44:47.000000000 -0600 -+++ perl-5.18.1/Porting/bisect-runner.pl 2019-08-21 09:07:10.885345427 -0600 -@@ -922,7 +922,7 @@ - my @libs; - # This is the current libswanted list from Configure, less the libs removed - # by current hints/linux.sh -- foreach my $lib (qw(sfio socket inet nsl nm ndbm gdbm dbm db malloc dl dld -+ foreach my $lib (qw(sfio socket inet nm ndbm gdbm dbm db malloc dl dld - ld sun m crypt sec util c cposix posix ucb BSD)) { - foreach my $dir (@paths) { - next unless -f "$dir/lib$lib.so"; -diff -ru perl-5.18.1.orig/Porting/config.sh perl-5.18.1/Porting/config.sh ---- perl-5.18.1.orig/Porting/config.sh 2013-08-11 20:44:47.000000000 -0600 -+++ perl-5.18.1/Porting/config.sh 2019-08-21 09:08:35.252345202 -0600 -@@ -795,12 +795,12 @@ - libc='/lib/libc-2.7.so' - libperl='libperl.a' - libpth='/usr/local/lib /lib /usr/lib' --libs='-lnsl -lgdbm -ldb -ldl -lm -lcrypt -lutil -lc -lgdbm_compat' -+libs='-lgdbm -ldb -ldl -lm -lcrypt -lutil -lc -lgdbm_compat' - libsdirs=' /usr/lib' --libsfiles=' libnsl.so libgdbm.so libdb.so libdl.so libm.so libcrypt.so libutil.so libc.so libgdbm_compat.so' --libsfound=' /usr/lib/libnsl.so /usr/lib/libgdbm.so /usr/lib/libdb.so /usr/lib/libdl.so /usr/lib/libm.so /usr/lib/libcrypt.so /usr/lib/libutil.so /usr/lib/libc.so /usr/lib/libgdbm_compat.so' -+libsfiles=' libgdbm.so libdb.so libdl.so libm.so libcrypt.so libutil.so libc.so libgdbm_compat.so' -+libsfound=' /usr/lib/libgdbm.so /usr/lib/libdb.so /usr/lib/libdl.so /usr/lib/libm.so /usr/lib/libcrypt.so /usr/lib/libutil.so /usr/lib/libc.so /usr/lib/libgdbm_compat.so' - libspath=' /usr/local/lib /lib /usr/lib' --libswanted='sfio socket inet nsl nm gdbm dbm db malloc dl dld ld sun m crypt sec util c cposix posix ucb BSD gdbm_compat' -+libswanted='sfio socket inet nm gdbm dbm db malloc dl dld ld sun m crypt sec util c cposix posix ucb BSD gdbm_compat' - libswanted_uselargefiles='' - line='' - lint='' -@@ -886,7 +886,7 @@ - perl_patchlevel='34948' - perl_static_inline='static __inline__' - perladmin='yourname@yourhost.yourplace.com' --perllibs='-lnsl -ldl -lm -lcrypt -lutil -lc' -+perllibs='-ldl -lm -lcrypt -lutil -lc' - perlpath='/opt/perl/bin/perl5.18.1' - pg='pg' - phostname='' -diff -ru perl-5.18.1.orig/win32/config.ce perl-5.18.1/win32/config.ce ---- perl-5.18.1.orig/win32/config.ce 2013-08-11 20:44:49.000000000 -0600 -+++ perl-5.18.1/win32/config.ce 2019-08-21 09:07:10.886345427 -0600 -@@ -749,7 +749,7 @@ - libsfiles='' - libsfound='' - libspath='' --libswanted='net socket inet nsl nm ndbm gdbm dbm db malloc dl dld ld sun m c cposix posix ndir dir crypt ucb bsd BSD PW x' -+libswanted='net socket inet nm ndbm gdbm dbm db malloc dl dld ld sun m c cposix posix ndir dir crypt ucb bsd BSD PW x' - line='line' - lint='' - lkflags='' -diff -ru perl-5.18.1.orig/win32/config.gc perl-5.18.1/win32/config.gc ---- perl-5.18.1.orig/win32/config.gc 2013-08-11 20:44:49.000000000 -0600 -+++ perl-5.18.1/win32/config.gc 2019-08-21 09:07:10.886345427 -0600 -@@ -775,8 +775,8 @@ - libsfiles='' - libsfound='' - libspath='' --libswanted='net socket inet nsl nm ndbm gdbm dbm db malloc dl dld ld sun m c cposix posix ndir dir crypt ucb bsd BSD PW x' --libswanted_uselargefiles='net socket inet nsl nm ndbm gdbm dbm db malloc dl dld ld sun m c cposix posix ndir dir crypt ucb bsd BSD PW x' -+libswanted='net socket inet nm ndbm gdbm dbm db malloc dl dld ld sun m c cposix posix ndir dir crypt ucb bsd BSD PW x' -+libswanted_uselargefiles='net socket inet nm ndbm gdbm dbm db malloc dl dld ld sun m c cposix posix ndir dir crypt ucb bsd BSD PW x' - line='line' - lint='' - lkflags='' -diff -ru perl-5.18.1.orig/win32/config.vc perl-5.18.1/win32/config.vc ---- perl-5.18.1.orig/win32/config.vc 2013-08-11 20:44:49.000000000 -0600 -+++ perl-5.18.1/win32/config.vc 2019-08-21 09:07:10.887345427 -0600 -@@ -774,8 +774,8 @@ - libsfiles='' - libsfound='' - libspath='' --libswanted='net socket inet nsl nm ndbm gdbm dbm db malloc dl dld ld sun m c cposix posix ndir dir crypt ucb bsd BSD PW x' --libswanted_uselargefiles='net socket inet nsl nm ndbm gdbm dbm db malloc dl dld ld sun m c cposix posix ndir dir crypt ucb bsd BSD PW x' -+libswanted='net socket inet nm ndbm gdbm dbm db malloc dl dld ld sun m c cposix posix ndir dir crypt ucb bsd BSD PW x' -+libswanted_uselargefiles='net socket inet nm ndbm gdbm dbm db malloc dl dld ld sun m c cposix posix ndir dir crypt ucb bsd BSD PW x' - line='line' - lint='' - lkflags='' diff --git a/omnibus/config/patches/perl/perl-5.22.1-remove_lnsl.patch b/omnibus/config/patches/perl/perl-5.22.1-remove_lnsl.patch deleted file mode 100644 index d232c003b..000000000 --- a/omnibus/config/patches/perl/perl-5.22.1-remove_lnsl.patch +++ /dev/null @@ -1,512 +0,0 @@ -diff -ru perl-5.22.1.orig/Configure perl-5.22.1/Configure ---- perl-5.22.1.orig/Configure 2015-10-17 06:38:37.000000000 -0600 -+++ perl-5.22.1/Configure 2019-08-21 09:12:01.271379908 -0600 -@@ -1454,7 +1454,7 @@ - : set usesocks on the Configure command line to enable socks. - : List of libraries we want. - : If anyone needs extra -lxxx, put those in a hint file. --libswanted="cl pthread socket bind inet nsl nm ndbm gdbm dbm db malloc dl ld" -+libswanted="cl pthread socket bind inet nm ndbm gdbm dbm db malloc dl ld" - libswanted="$libswanted sun m crypt sec util c cposix posix ucb bsd BSD" - : We probably want to search /usr/shlib before most other libraries. - : This is only used by the lib/ExtUtils/MakeMaker.pm routine extliblist. -diff -ru perl-5.22.1.orig/configure.com perl-5.22.1/configure.com ---- perl-5.22.1.orig/configure.com 2015-10-17 06:38:37.000000000 -0600 -+++ perl-5.22.1/configure.com 2019-08-21 09:12:01.271379908 -0600 -@@ -119,7 +119,7 @@ - $!: machines, like the mips. Usually, it should be empty. !sfn - $!plibpth='' !sfn - $!: List of libraries we want. !sfn --$!libswanted='net socket inet nsl nm ndbm gdbm dbm db malloc dl' !sfn -+$!libswanted='net socket inet nm ndbm gdbm dbm db malloc dl' !sfn - $!libswanted="$libswanted ld sun m c cposix posix ndir dir crypt" !sfn - $!libswanted="$libswanted ucb bsd BSD PW x" !sfn - $!: We probably want to search /usr/shlib before most other libraries. !sfn -diff -ru perl-5.22.1.orig/cpan/Config-Perl-V/t/20_plv56.t perl-5.22.1/cpan/Config-Perl-V/t/20_plv56.t ---- perl-5.22.1.orig/cpan/Config-Perl-V/t/20_plv56.t 2015-10-17 06:31:54.000000000 -0600 -+++ perl-5.22.1/cpan/Config-Perl-V/t/20_plv56.t 2019-08-21 09:12:01.272379909 -0600 -@@ -58,8 +58,8 @@ - Linker and Libraries: - ld='cc', ldflags ='-L/pro/local/lib' - libpth=/pro/local/lib /lib /usr/lib /usr/local/lib -- libs=-lnsl -lgdbm -ldb -ldl -lm -lc -lcrypt -lutil -- perllibs=-lnsl -ldl -lm -lc -lcrypt -lutil -+ libs=-lgdbm -ldb -ldl -lm -lc -lcrypt -lutil -+ perllibs=-ldl -lm -lc -lcrypt -lutil - libc=/lib/libc-2.10.1.so, so=so, useshrplib=false, libperl=libperl.a - Dynamic Linking: - dlsrc=dl_dlopen.xs, dlext=so, d_dlsymun=undef, ccdlflags='-rdynamic' -diff -ru perl-5.22.1.orig/cpan/Config-Perl-V/t/21_plv58.t perl-5.22.1/cpan/Config-Perl-V/t/21_plv58.t ---- perl-5.22.1.orig/cpan/Config-Perl-V/t/21_plv58.t 2015-10-17 06:31:54.000000000 -0600 -+++ perl-5.22.1/cpan/Config-Perl-V/t/21_plv58.t 2019-08-21 09:12:01.272379909 -0600 -@@ -62,8 +62,8 @@ - Linker and Libraries: - ld='cc', ldflags ='-L/pro/local/lib' - libpth=/pro/local/lib /lib /usr/lib /usr/local/lib -- libs=-lnsl -lgdbm -ldb -ldl -lm -lcrypt -lutil -lpthread -lc -- perllibs=-lnsl -ldl -lm -lcrypt -lutil -lpthread -lc -+ libs=-lgdbm -ldb -ldl -lm -lcrypt -lutil -lpthread -lc -+ perllibs=-ldl -lm -lcrypt -lutil -lpthread -lc - libc=/lib/libc-2.11.2.so, so=so, useshrplib=false, libperl=libperl.a - gnulibc_version='2.11.2' - Dynamic Linking: -diff -ru perl-5.22.1.orig/cpan/Config-Perl-V/t/22_plv510.t perl-5.22.1/cpan/Config-Perl-V/t/22_plv510.t ---- perl-5.22.1.orig/cpan/Config-Perl-V/t/22_plv510.t 2015-10-17 06:31:54.000000000 -0600 -+++ perl-5.22.1/cpan/Config-Perl-V/t/22_plv510.t 2019-08-21 09:12:01.272379909 -0600 -@@ -52,8 +52,8 @@ - Linker and Libraries: - ld='cc', ldflags ='-L/pro/local/lib' - libpth=/pro/local/lib /lib /usr/lib /usr/local/lib -- libs=-lnsl -lgdbm -ldb -ldl -lm -lcrypt -lutil -lc -- perllibs=-lnsl -ldl -lm -lcrypt -lutil -lc -+ libs=-lgdbm -ldb -ldl -lm -lcrypt -lutil -lc -+ perllibs=-ldl -lm -lcrypt -lutil -lc - libc=/lib/libc-2.6.1.so, so=so, useshrplib=false, libperl=libperl.a - gnulibc_version='2.6.1' - Dynamic Linking: -diff -ru perl-5.22.1.orig/cpan/Config-Perl-V/t/23_plv512.t perl-5.22.1/cpan/Config-Perl-V/t/23_plv512.t ---- perl-5.22.1.orig/cpan/Config-Perl-V/t/23_plv512.t 2015-10-17 06:31:54.000000000 -0600 -+++ perl-5.22.1/cpan/Config-Perl-V/t/23_plv512.t 2019-08-21 09:12:01.272379909 -0600 -@@ -63,8 +63,8 @@ - Linker and Libraries: - ld='/usr/bin/ld', ldflags ='-L/pro/local/lib +DD64 -L/usr/lib/hpux64' - libpth=/pro/local/lib /usr/lib/hpux64 /lib /usr/lib /usr/ccs/lib /usr/local/lib -- libs=-lcl -lpthread -lnsl -lnm -ldb -ldl -ldld -lm -lsec -lc -- perllibs=-lcl -lpthread -lnsl -lnm -ldl -ldld -lm -lsec -lc -+ libs=-lcl -lpthread -lnm -ldb -ldl -ldld -lm -lsec -lc -+ perllibs=-lcl -lpthread -lnm -ldl -ldld -lm -lsec -lc - libc=/usr/lib/hpux64/libc.so, so=so, useshrplib=false, libperl=libperl.a - gnulibc_version='' - Dynamic Linking: -diff -ru perl-5.22.1.orig/cpan/Config-Perl-V/t/24_plv514.t perl-5.22.1/cpan/Config-Perl-V/t/24_plv514.t ---- perl-5.22.1.orig/cpan/Config-Perl-V/t/24_plv514.t 2015-10-17 06:31:54.000000000 -0600 -+++ perl-5.22.1/cpan/Config-Perl-V/t/24_plv514.t 2019-08-21 09:12:01.272379909 -0600 -@@ -64,8 +64,8 @@ - Linker and Libraries: - ld='ld', ldflags ='-L/usr/local/ppc64/lib64 -b64 -q64 -L/pro/local/lib -brtl -bdynamic -b64' - libpth=/usr/local/ppc64/lib64 /lib /usr/lib /usr/ccs/lib /usr/local/lib /usr/lib64 -- libs=-lbind -lnsl -ldbm -ldb -ldl -lld -lm -lcrypt -lc -- perllibs=-lbind -lnsl -ldl -lld -lm -lcrypt -lc -+ libs=-lbind -ldbm -ldb -ldl -lld -lm -lcrypt -lc -+ perllibs=-lbind -ldl -lld -lm -lcrypt -lc - libc=/lib/libc.a, so=a, useshrplib=false, libperl=libperl.a - gnulibc_version='' - Dynamic Linking: -diff -ru perl-5.22.1.orig/cpan/Config-Perl-V/t/25_plv516.t perl-5.22.1/cpan/Config-Perl-V/t/25_plv516.t ---- perl-5.22.1.orig/cpan/Config-Perl-V/t/25_plv516.t 2015-10-17 06:31:54.000000000 -0600 -+++ perl-5.22.1/cpan/Config-Perl-V/t/25_plv516.t 2019-08-21 09:12:01.272379909 -0600 -@@ -64,8 +64,8 @@ - Linker and Libraries: - ld='cc', ldflags ='-L/pro/local/lib -fstack-protector' - libpth=/pro/local/lib /lib /usr/lib /usr/local/lib -- libs=-lnsl -lgdbm -ldb -ldl -lm -lcrypt -lutil -lc -lgdbm_compat -- perllibs=-lnsl -ldl -lm -lcrypt -lutil -lc -+ libs=-lgdbm -ldb -ldl -lm -lcrypt -lutil -lc -lgdbm_compat -+ perllibs=-ldl -lm -lcrypt -lutil -lc - libc=/lib/libc-2.15.so, so=so, useshrplib=false, libperl=libperl.a - gnulibc_version='2.15' - Dynamic Linking: -diff -ru perl-5.22.1.orig/cpan/Config-Perl-V/t/26_plv5182.t perl-5.22.1/cpan/Config-Perl-V/t/26_plv5182.t ---- perl-5.22.1.orig/cpan/Config-Perl-V/t/26_plv5182.t 2015-10-17 06:31:54.000000000 -0600 -+++ perl-5.22.1/cpan/Config-Perl-V/t/26_plv5182.t 2019-08-21 09:12:01.272379909 -0600 -@@ -89,8 +89,8 @@ - Linker and Libraries: - ld='cc', ldflags ='-L/pro/local/lib -fstack-protector' - libpth=/pro/local/lib /lib /usr/lib /usr/local/lib -- libs=-lnsl -lgdbm -ldb -ldl -lm -lcrypt -lutil -lc -lgdbm_compat -- perllibs=-lnsl -ldl -lm -lcrypt -lutil -lc -+ libs=-lgdbm -ldb -ldl -lm -lcrypt -lutil -lc -lgdbm_compat -+ perllibs=-ldl -lm -lcrypt -lutil -lc - libc=/lib/libc-2.18.so, so=so, useshrplib=false, libperl=libperl.a - gnulibc_version='2.18' - Dynamic Linking: -diff -ru perl-5.22.1.orig/cpan/Config-Perl-V/t/26_plv518.t perl-5.22.1/cpan/Config-Perl-V/t/26_plv518.t ---- perl-5.22.1.orig/cpan/Config-Perl-V/t/26_plv518.t 2015-10-17 06:31:54.000000000 -0600 -+++ perl-5.22.1/cpan/Config-Perl-V/t/26_plv518.t 2019-08-21 09:12:01.272379909 -0600 -@@ -89,8 +89,8 @@ - Linker and Libraries: - ld='cc', ldflags ='-L/pro/local/lib -fstack-protector' - libpth=/pro/local/lib /lib /usr/lib /usr/local/lib -- libs=-lnsl -lgdbm -ldb -ldl -lm -lcrypt -lutil -lc -lgdbm_compat -- perllibs=-lnsl -ldl -lm -lcrypt -lutil -lc -+ libs=-lgdbm -ldb -ldl -lm -lcrypt -lutil -lc -lgdbm_compat -+ perllibs=-ldl -lm -lcrypt -lutil -lc - libc=/lib/libc-2.17.so, so=so, useshrplib=false, libperl=libperl.a - gnulibc_version='2.17' - Dynamic Linking: -diff -ru perl-5.22.1.orig/cpan/Config-Perl-V/t/27_plv5200.t perl-5.22.1/cpan/Config-Perl-V/t/27_plv5200.t ---- perl-5.22.1.orig/cpan/Config-Perl-V/t/27_plv5200.t 2015-10-17 06:31:54.000000000 -0600 -+++ perl-5.22.1/cpan/Config-Perl-V/t/27_plv5200.t 2019-08-21 09:12:01.272379909 -0600 -@@ -91,8 +91,8 @@ - Linker and Libraries: - ld='cc', ldflags ='-L/pro/local/lib -fstack-protector' - libpth=/usr/local/lib /usr/lib/gcc/i586-suse-linux/4.8/include-fixed /usr/lib/gcc/i586-suse-linux/4.8/../../../../i586-suse-linux/lib /usr/lib /pro/local/lib /lib -- libs=-lnsl -lgdbm -ldb -ldl -lm -lcrypt -lutil -lpthread -lc -lgdbm_compat -- perllibs=-lnsl -ldl -lm -lcrypt -lutil -lpthread -lc -+ libs=-lgdbm -ldb -ldl -lm -lcrypt -lutil -lpthread -lc -lgdbm_compat -+ perllibs=-ldl -lm -lcrypt -lutil -lpthread -lc - libc=libc-2.18.so, so=so, useshrplib=false, libperl=libperl.a - gnulibc_version='2.18' - Dynamic Linking: -diff -ru perl-5.22.1.orig/Cross/config.sh-arm-linux perl-5.22.1/Cross/config.sh-arm-linux ---- perl-5.22.1.orig/Cross/config.sh-arm-linux 2015-10-18 11:26:26.000000000 -0600 -+++ perl-5.22.1/Cross/config.sh-arm-linux 2019-08-21 09:12:19.907386879 -0600 -@@ -838,12 +838,12 @@ - libc='/lib/libc-2.2.2.so' - libperl='libperl.so' - libpth='/usr/local/lib /lib /usr/lib' --libs='-lnsl -ldl -lm -lcrypt -lutil -lc' -+libs='-ldl -lm -lcrypt -lutil -lc' - libsdirs=' /usr/lib' --libsfiles=' libnsl.so libdl.so libm.so libcrypt.so libutil.so libc.so' --libsfound=' /usr/lib/libnsl.so /usr/lib/libdl.so /usr/lib/libm.so /usr/lib/libcrypt.so /usr/lib/libutil.so /usr/lib/libc.so' -+libsfiles=' libdl.so libm.so libcrypt.so libutil.so libc.so' -+libsfound=' /usr/lib/libdl.so /usr/lib/libm.so /usr/lib/libcrypt.so /usr/lib/libutil.so /usr/lib/libc.so' - libspath=' /usr/local/lib /lib /usr/lib' --libswanted='socket bind inet nsl nm ndbm gdbm dbm db malloc dl ld sun m crypt sec util c cposix posix ucb BSD' -+libswanted='socket bind inet nm ndbm gdbm dbm db malloc dl ld sun m crypt sec util c cposix posix ucb BSD' - libswanted_uselargefiles='' - line='' - lint='' -@@ -927,7 +927,7 @@ - perl_patchlevel='' - perl_static_inline='static' - perladmin='red@criticalintegration.com' --perllibs='-lnsl -ldl -lm -lcrypt -lutil -lc' -+perllibs='-ldl -lm -lcrypt -lutil -lc' - perlpath='/usr/bin/perl' - pg='pg' - phostname='hostname' -diff -ru perl-5.22.1.orig/Cross/config.sh-arm-linux-n770 perl-5.22.1/Cross/config.sh-arm-linux-n770 ---- perl-5.22.1.orig/Cross/config.sh-arm-linux-n770 2015-10-18 11:26:52.000000000 -0600 -+++ perl-5.22.1/Cross/config.sh-arm-linux-n770 2019-08-21 09:12:19.907386879 -0600 -@@ -744,12 +744,12 @@ - libc='/lib/libc-2.2.2.so' - libperl='libperl.arma' - libpth='/usr/local/lib /lib /usr/lib' --libs='-lnsl -ldl -lm -lcrypt -lutil -lc' -+libs='-ldl -lm -lcrypt -lutil -lc' - libsdirs=' /usr/lib' --libsfiles=' libnsl.so libdl.so libm.so libcrypt.so libutil.so libc.so' --libsfound=' /usr/lib/libnsl.so /usr/lib/libdl.so /usr/lib/libm.so /usr/lib/libcrypt.so /usr/lib/libutil.so /usr/lib/libc.so' -+libsfiles=' libdl.so libm.so libcrypt.so libutil.so libc.so' -+libsfound=' /usr/lib/libdl.so /usr/lib/libm.so /usr/lib/libcrypt.so /usr/lib/libutil.so /usr/lib/libc.so' - libspath=' /usr/local/lib /lib /usr/lib' --libswanted='socket bind inet nsl nm ndbm gdbm dbm db malloc dl ld sun m crypt sec util c cposix posix ucb BSD' -+libswanted='socket bind inet nm ndbm gdbm dbm db malloc dl ld sun m crypt sec util c cposix posix ucb BSD' - libswanted_uselargefiles='' - line='' - lint='' -@@ -831,7 +831,7 @@ - perl='' - perl_patchlevel='' - perladmin='red@criticalintegration.com' --perllibs='-lnsl -ldl -lm -lcrypt -lutil -lc' -+perllibs='-ldl -lm -lcrypt -lutil -lc' - perlpath='/usr/bin/perl' - pg='pg' - phostname='hostname' -diff -ru perl-5.22.1.orig/hints/aix_4.sh perl-5.22.1/hints/aix_4.sh ---- perl-5.22.1.orig/hints/aix_4.sh 2015-10-17 06:32:14.000000000 -0600 -+++ perl-5.22.1/hints/aix_4.sh 2019-08-21 09:12:01.273379909 -0600 -@@ -583,7 +583,7 @@ - - *** - *** You seem to be compiling in AIX for the OS/400 PASE environment. --*** I'm not going to use the AIX bind, nsl, and possible util libraries, then. -+*** I'm not going to use the AIX bind, and possible util libraries, then. - *** I'm also not going to install perl as /usr/bin/perl. - *** Perl will be installed under $prefix. - *** For instructions how to install this build from AIX to PASE, -@@ -591,7 +591,7 @@ - *** about "Operating system name". - *** - EOF -- set `echo " $libswanted " | sed -e 's@ bind @ @' -e 's@ nsl @ @' -e 's@ util @ @'` -+ set `echo " $libswanted " | sed -e 's@ bind @ @' -e 's@ util @ @'` - shift - libswanted="$*" - installusrbinperl="$undef" -diff -ru perl-5.22.1.orig/hints/aix.sh perl-5.22.1/hints/aix.sh ---- perl-5.22.1.orig/hints/aix.sh 2015-10-17 06:38:37.000000000 -0600 -+++ perl-5.22.1/hints/aix.sh 2019-08-21 09:12:01.273379909 -0600 -@@ -504,7 +504,7 @@ - - *** - *** You seem to be compiling in AIX for the OS/400 PASE environment. --*** I'm not going to use the AIX bind, nsl, and possible util libraries, then. -+*** I'm not going to use the AIX bind, and possible util libraries, then. - *** I'm also not going to install perl as /usr/bin/perl. - *** Perl will be installed under $prefix. - *** For instructions how to install this build from AIX to PASE, -@@ -512,7 +512,7 @@ - *** about "Operating system name". - *** - EOF -- set `echo " $libswanted " | sed -e 's@ bind @ @' -e 's@ nsl @ @' -e 's@ util @ @'` -+ set `echo " $libswanted " | sed -e 's@ bind @ @' -e 's@ util @ @'` - shift - libswanted="$*" - installusrbinperl="$undef" -diff -ru perl-5.22.1.orig/hints/epix.sh perl-5.22.1/hints/epix.sh ---- perl-5.22.1.orig/hints/epix.sh 2015-10-17 06:32:14.000000000 -0600 -+++ perl-5.22.1/hints/epix.sh 2019-08-21 09:12:01.273379909 -0600 -@@ -37,7 +37,7 @@ - # Old version had this, but I'm not sure why since the old version - # also mucked around with libswanted. This is also definitely wrong - # if the user is trying to use DB_File or GDBM_File. --# libs='-lsocket -lnsl -ldbm -ldl -lc -lcrypt -lm -lucb' -+# libs='-lsocket -ldbm -ldl -lc -lcrypt -lm -lucb' - - # We include support for using libraries in /usr/ucblib, but the setting - # of libswanted excludes some libraries found there. You may want to -diff -ru perl-5.22.1.orig/hints/gnu.sh perl-5.22.1/hints/gnu.sh ---- perl-5.22.1.orig/hints/gnu.sh 2015-10-17 06:32:14.000000000 -0600 -+++ perl-5.22.1/hints/gnu.sh 2019-08-21 09:12:01.273379909 -0600 -@@ -4,7 +4,7 @@ - - # libnsl is unusable on the Hurd. - # XXX remove this once SUNRPC is implemented. --set `echo X "$libswanted "| sed -e 's/ bsd / /' -e 's/ nsl / /' -e 's/ c / pthread /'` -+set `echo X "$libswanted "| sed -e 's/ bsd / /' -e 's/ c / pthread /'` - shift - libswanted="$*" - -diff -ru perl-5.22.1.orig/hints/irix_5.sh perl-5.22.1/hints/irix_5.sh ---- perl-5.22.1.orig/hints/irix_5.sh 2015-10-17 06:32:14.000000000 -0600 -+++ perl-5.22.1/hints/irix_5.sh 2019-08-21 09:12:01.273379909 -0600 -@@ -27,9 +27,9 @@ - esac - - lddlflags="-shared" --# For some reason we don't want -lsocket -lnsl or -ldl. Can anyone -+# For some reason we don't want -lsocket or -ldl. Can anyone - # contribute an explanation? --set `echo X "$libswanted "|sed -e 's/ socket / /' -e 's/ nsl / /' -e 's/ dl / /'` -+set `echo X "$libswanted "|sed -e 's/ socket / /' -e 's/ dl / /'` - shift - libswanted="$*" - -diff -ru perl-5.22.1.orig/hints/irix_6_0.sh perl-5.22.1/hints/irix_6_0.sh ---- perl-5.22.1.orig/hints/irix_6_0.sh 2015-10-17 06:32:14.000000000 -0600 -+++ perl-5.22.1/hints/irix_6_0.sh 2019-08-21 09:12:01.273379909 -0600 -@@ -19,7 +19,7 @@ - lddlflags="-32 -shared" - - # We don't want these libraries. Anyone know why? --set `echo X "$libswanted "|sed -e 's/ socket / /' -e 's/ nsl / /' -e 's/ dl / /'` -+set `echo X "$libswanted "|sed -e 's/ socket / /' -e 's/ dl / /'` - shift - libswanted="$*" - # -@@ -29,7 +29,7 @@ - # taken from irix_5.sh . Changes from irix_5.sh: - # Olimit and nested comments (warning 1009) no longer accepted - # -OPT:fold_arith_limit so POSIX module will optimize --# no 64bit versions of sun, crypt, nsl, socket, dl dso's available -+# no 64bit versions of sun, crypt, socket, dl dso's available - # as of IRIX 6.0.1 so omit those from libswanted line via `sed'. - - # perl 5 built with this hints file passes most tests (`make test'). -@@ -38,7 +38,7 @@ - # i_time='define' - # ccflags="$ccflags -D_POSIX_SOURCE -ansiposix -D_BSD_TYPES -woff 1009 -OPT:fold_arith_limit=1046" - # lddlflags="-shared" --# set `echo X "$libswanted "|sed -e 's/ socket / /' -e 's/ sun / /' -e 's/ crypt / /' -e 's/ nsl / /' -e 's/ dl / /'` -+# set `echo X "$libswanted "|sed -e 's/ socket / /' -e 's/ sun / /' -e 's/ crypt / /' -e 's/ dl / /'` - # shift - # libswanted="$*" - -diff -ru perl-5.22.1.orig/hints/irix_6_1.sh perl-5.22.1/hints/irix_6_1.sh ---- perl-5.22.1.orig/hints/irix_6_1.sh 2015-10-17 06:32:14.000000000 -0600 -+++ perl-5.22.1/hints/irix_6_1.sh 2019-08-21 09:12:01.273379909 -0600 -@@ -19,7 +19,7 @@ - lddlflags="-32 -shared" - - # We don't want these libraries. Anyone know why? --set `echo X "$libswanted "|sed -e 's/ socket / /' -e 's/ nsl / /' -e 's/ dl / /'` -+set `echo X "$libswanted "|sed -e 's/ socket / /' -e 's/ dl / /'` - shift - libswanted="$*" - # -@@ -29,7 +29,7 @@ - # taken from irix_5.sh . Changes from irix_5.sh: - # Olimit and nested comments (warning 1009) no longer accepted - # -OPT:fold_arith_limit so POSIX module will optimize --# no 64bit versions of sun, crypt, nsl, socket, dl dso's available -+# no 64bit versions of sun, crypt, socket, dl dso's available - # as of IRIX 6.0.1 so omit those from libswanted line via `sed'. - - # perl 5 built with this hints file passes most tests (`make test'). -@@ -38,7 +38,7 @@ - # i_time='define' - # ccflags="$ccflags -D_POSIX_SOURCE -ansiposix -D_BSD_TYPES -woff 1009 -OPT:fold_arith_limit=1046" - # lddlflags="-shared" --# set `echo X "$libswanted "|sed -e 's/ socket / /' -e 's/ sun / /' -e 's/ crypt / /' -e 's/ nsl / /' -e 's/ dl / /'` -+# set `echo X "$libswanted "|sed -e 's/ socket / /' -e 's/ sun / /' -e 's/ crypt / /' -e 's/ dl / /'` - # shift - # libswanted="$*" - -diff -ru perl-5.22.1.orig/hints/irix_6.sh perl-5.22.1/hints/irix_6.sh ---- perl-5.22.1.orig/hints/irix_6.sh 2015-10-18 06:40:25.000000000 -0600 -+++ perl-5.22.1/hints/irix_6.sh 2019-08-21 09:12:01.273379909 -0600 -@@ -388,7 +388,7 @@ - # Socket networking is in libc, these are not installed by default, - # and just slow perl down. (scotth@sgi.com) - # librt contains nothing we need (some places need it for Time::HiRes) --jhi --set `echo X "$libswanted "|sed -e 's/ socket / /' -e 's/ nsl / /' -e 's/ dl / /' -e 's/ rt / /'` -+set `echo X "$libswanted "|sed -e 's/ socket / /' -e 's/ dl / /' -e 's/ rt / /'` - shift - libswanted="$*" - -diff -ru perl-5.22.1.orig/hints/powerux.sh perl-5.22.1/hints/powerux.sh ---- perl-5.22.1.orig/hints/powerux.sh 2015-10-17 06:32:14.000000000 -0600 -+++ perl-5.22.1/hints/powerux.sh 2019-08-21 09:12:01.274379910 -0600 -@@ -27,11 +27,11 @@ - exit 2 - fi - --# We DO NOT want -lmalloc or -lPW, we DO need -lgen to follow -lnsl, so -+# We DO NOT want -lmalloc or -lPW, we DO need -lgen to follow, so - # fixup libswanted to reflect that desire (also need -lresolv if you want - # DNS name lookup to work, which seems desirable :-). - # --libswanted=`echo ' '$libswanted' ' | sed -e 's/ malloc / /' -e 's/ PW / /' -e 's/ nsl / nsl gen resolv /'` -+libswanted=`echo ' '$libswanted' ' | sed -e 's/ malloc / /' -e 's/ PW / /'` - - # We DO NOT want /usr/ucblib in glibpth - # -diff -ru perl-5.22.1.orig/INSTALL perl-5.22.1/INSTALL ---- perl-5.22.1.orig/INSTALL 2015-10-18 11:46:25.000000000 -0600 -+++ perl-5.22.1/INSTALL 2019-08-21 09:12:01.274379910 -0600 -@@ -1617,7 +1617,7 @@ - undefined symbols, check the libs variable in the config.sh file. It - should look something like - -- libs='-lsocket -lnsl -ldl -lm -lc' -+ libs='-lsocket -ldl -lm -lc' - - The exact libraries will vary from system to system, but you typically - need to include at least the math library -lm. Normally, Configure -diff -ru perl-5.22.1.orig/NetWare/config.wc perl-5.22.1/NetWare/config.wc ---- perl-5.22.1.orig/NetWare/config.wc 2015-10-17 06:38:37.000000000 -0600 -+++ perl-5.22.1/NetWare/config.wc 2019-08-21 09:12:01.274379910 -0600 -@@ -818,7 +818,7 @@ - libsfiles='' - libsfound='' - libspath='' --libswanted='net socket inet nsl nm ndbm gdbm dbm db malloc dl ld sun m c cposix posix ndir dir crypt ucb bsd BSD PW x' -+libswanted='net socket inet nm ndbm gdbm dbm db malloc dl ld sun m c cposix posix ndir dir crypt ucb bsd BSD PW x' - line='line' - lint='' - lkflags='' -diff -ru perl-5.22.1.orig/plan9/config_sh.sample perl-5.22.1/plan9/config_sh.sample ---- perl-5.22.1.orig/plan9/config_sh.sample 2015-10-18 11:39:19.000000000 -0600 -+++ perl-5.22.1/plan9/config_sh.sample 2019-08-21 09:12:01.274379910 -0600 -@@ -825,7 +825,7 @@ - libsfiles='' - libsfound='' - libspath=' /lib' --libswanted='socket bind inet nsl nm ndbm gdbm dbm db malloc dl ld sun m c cposix posix ndir dir crypt sec ucb bsd BSD PW x util' -+libswanted='socket bind inet nm ndbm gdbm dbm db malloc dl ld sun m c cposix posix ndir dir crypt sec ucb bsd BSD PW x util' - libswanted_uselargefiles='' - line='' - lint='' -diff -ru perl-5.22.1.orig/pod/perlrun.pod perl-5.22.1/pod/perlrun.pod ---- perl-5.22.1.orig/pod/perlrun.pod 2015-10-17 06:32:18.000000000 -0600 -+++ perl-5.22.1/pod/perlrun.pod 2019-08-21 09:12:01.274379910 -0600 -@@ -874,11 +874,11 @@ - $ perl -V:libc - libc='/lib/libc-2.2.4.so'; - $ perl -V:lib. -- libs='-lnsl -lgdbm -ldb -ldl -lm -lcrypt -lutil -lc'; -+ libs='-lgdbm -ldb -ldl -lm -lcrypt -lutil -lc'; - libc='/lib/libc-2.2.4.so'; - $ perl -V:lib.* - libpth='/usr/local/lib /lib /usr/lib'; -- libs='-lnsl -lgdbm -ldb -ldl -lm -lcrypt -lutil -lc'; -+ libs='-lgdbm -ldb -ldl -lm -lcrypt -lutil -lc'; - lib_ext='.a'; - libc='/lib/libc-2.2.4.so'; - libperl='libperl.a'; -diff -ru perl-5.22.1.orig/Porting/bisect-runner.pl perl-5.22.1/Porting/bisect-runner.pl ---- perl-5.22.1.orig/Porting/bisect-runner.pl 2015-10-17 06:38:37.000000000 -0600 -+++ perl-5.22.1/Porting/bisect-runner.pl 2019-08-21 09:12:01.275379910 -0600 -@@ -1269,7 +1269,7 @@ - my @libs; - # This is the current libswanted list from Configure, less the libs removed - # by current hints/linux.sh -- foreach my $lib (qw(sfio socket inet nsl nm ndbm gdbm dbm db malloc dl -+ foreach my $lib (qw(sfio socket inet nm ndbm gdbm dbm db malloc dl - ld sun m crypt sec util c cposix posix ucb BSD)) { - foreach my $dir (@paths) { - # Note the wonderful consistency of dot-or-not in the config vars: -diff -ru perl-5.22.1.orig/Porting/config.sh perl-5.22.1/Porting/config.sh ---- perl-5.22.1.orig/Porting/config.sh 2015-10-18 11:34:00.000000000 -0600 -+++ perl-5.22.1/Porting/config.sh 2019-08-21 09:12:19.908386879 -0600 -@@ -856,12 +856,12 @@ - libc='libc-2.18.so' - libperl='libperl.a' - libpth='/usr/local/lib /usr/lib/gcc/i586-suse-linux/4.8/include-fixed /usr/lib/gcc/i586-suse-linux/4.8/../../../../i586-suse-linux/lib /usr/lib /pro/local/lib /lib' --libs='-lnsl -lgdbm -ldb -ldl -lm -lcrypt -lutil -lc -lgdbm_compat' -+libs='-lgdbm -ldb -ldl -lm -lcrypt -lutil -lc -lgdbm_compat' - libsdirs=' /usr/lib' --libsfiles=' libnsl.so libgdbm.so libdb.so libdl.so libm.so libcrypt.so libutil.so libc.so libgdbm_compat.so' --libsfound=' /usr/lib/libnsl.so /usr/lib/libgdbm.so /usr/lib/libdb.so /usr/lib/libdl.so /usr/lib/libm.so /usr/lib/libcrypt.so /usr/lib/libutil.so /usr/lib/libc.so /usr/lib/libgdbm_compat.so' -+libsfiles=' libgdbm.so libdb.so libdl.so libm.so libcrypt.so libutil.so libc.so libgdbm_compat.so' -+libsfound=' /usr/lib/libgdbm.so /usr/lib/libdb.so /usr/lib/libdl.so /usr/lib/libm.so /usr/lib/libcrypt.so /usr/lib/libutil.so /usr/lib/libc.so /usr/lib/libgdbm_compat.so' - libspath=' /usr/local/lib /usr/lib/gcc/i586-suse-linux/4.8/include-fixed /usr/lib/gcc/i586-suse-linux/4.8/../../../../i586-suse-linux/lib /usr/lib /pro/local/lib /lib' --libswanted='socket inet nsl nm gdbm dbm db malloc dl ld sun m crypt sec util c cposix posix ucb BSD gdbm_compat' -+libswanted='socket inet nm gdbm dbm db malloc dl ld sun m crypt sec util c cposix posix ucb BSD gdbm_compat' - libswanted_uselargefiles='' - line='' - lint='' -@@ -945,7 +945,7 @@ - perl_patchlevel='' - perl_static_inline='static __inline__' - perladmin='hmbrand@cpan.org' --perllibs='-lnsl -ldl -lm -lcrypt -lutil -lc' -+perllibs='-ldl -lm -lcrypt -lutil -lc' - perlpath='/pro/bin/perl5.22.1' - pg='pg' - phostname='hostname' -diff -ru perl-5.22.1.orig/win32/config.ce perl-5.22.1/win32/config.ce ---- perl-5.22.1.orig/win32/config.ce 2015-10-17 06:38:38.000000000 -0600 -+++ perl-5.22.1/win32/config.ce 2019-08-21 09:12:01.275379910 -0600 -@@ -810,7 +810,7 @@ - libsfiles='' - libsfound='' - libspath='' --libswanted='net socket inet nsl nm ndbm gdbm dbm db malloc dl ld sun m c cposix posix ndir dir crypt ucb bsd BSD PW x' -+libswanted='net socket inet nm ndbm gdbm dbm db malloc dl ld sun m c cposix posix ndir dir crypt ucb bsd BSD PW x' - line='line' - lint='' - lkflags='' -diff -ru perl-5.22.1.orig/win32/config.gc perl-5.22.1/win32/config.gc ---- perl-5.22.1.orig/win32/config.gc 2015-10-17 06:38:38.000000000 -0600 -+++ perl-5.22.1/win32/config.gc 2019-08-21 09:12:01.275379910 -0600 -@@ -836,8 +836,8 @@ - libsfiles='' - libsfound='' - libspath='' --libswanted='net socket inet nsl nm ndbm gdbm dbm db malloc dl ld sun m c cposix posix ndir dir crypt ucb bsd BSD PW x' --libswanted_uselargefiles='net socket inet nsl nm ndbm gdbm dbm db malloc dl ld sun m c cposix posix ndir dir crypt ucb bsd BSD PW x' -+libswanted='net socket inet nm ndbm gdbm dbm db malloc dl ld sun m c cposix posix ndir dir crypt ucb bsd BSD PW x' -+libswanted_uselargefiles='net socket inet nm ndbm gdbm dbm db malloc dl ld sun m c cposix posix ndir dir crypt ucb bsd BSD PW x' - line='line' - lint='' - lkflags='' -diff -ru perl-5.22.1.orig/win32/config.vc perl-5.22.1/win32/config.vc ---- perl-5.22.1.orig/win32/config.vc 2015-10-17 06:38:38.000000000 -0600 -+++ perl-5.22.1/win32/config.vc 2019-08-21 09:12:01.275379910 -0600 -@@ -835,8 +835,8 @@ - libsfiles='' - libsfound='' - libspath='' --libswanted='net socket inet nsl nm ndbm gdbm dbm db malloc dl ld sun m c cposix posix ndir dir crypt ucb bsd BSD PW x' --libswanted_uselargefiles='net socket inet nsl nm ndbm gdbm dbm db malloc dl ld sun m c cposix posix ndir dir crypt ucb bsd BSD PW x' -+libswanted='net socket inet nm ndbm gdbm dbm db malloc dl ld sun m c cposix posix ndir dir crypt ucb bsd BSD PW x' -+libswanted_uselargefiles='net socket inet nm ndbm gdbm dbm db malloc dl ld sun m c cposix posix ndir dir crypt ucb bsd BSD PW x' - line='line' - lint='' - lkflags='' diff --git a/omnibus/config/patches/perl/perl-5.30.0-remove_lnsl.patch b/omnibus/config/patches/perl/perl-5.30.0-remove_lnsl.patch deleted file mode 100644 index 48b63f567..000000000 --- a/omnibus/config/patches/perl/perl-5.30.0-remove_lnsl.patch +++ /dev/null @@ -1,518 +0,0 @@ -diff -ur perl-5.30.0.orig/Configure perl-5.30.0/Configure ---- perl-5.30.0.orig/Configure 2019-05-11 05:50:20.000000000 -0400 -+++ perl-5.30.0/Configure 2019-10-14 17:37:29.512567849 -0400 -@@ -1487,7 +1487,7 @@ - usereentrant='undef' - : List of libraries we want. - : If anyone needs extra -lxxx, put those in a hint file. --libswanted="cl pthread socket bind inet nsl ndbm gdbm dbm db malloc dl ld" -+libswanted="cl pthread socket bind inet ndbm gdbm dbm db malloc dl ld" - libswanted="$libswanted sun m crypt sec util c cposix posix ucb bsd BSD" - : We probably want to search /usr/shlib before most other libraries. - : This is only used by the lib/ExtUtils/MakeMaker.pm routine extliblist. -diff -ur perl-5.30.0.orig/configure.com perl-5.30.0/configure.com ---- perl-5.30.0.orig/configure.com 2019-05-11 05:50:20.000000000 -0400 -+++ perl-5.30.0/configure.com 2019-10-14 17:35:46.608063565 -0400 -@@ -117,7 +117,7 @@ - $!: machines, like the mips. Usually, it should be empty. !sfn - $!plibpth='' !sfn - $!: List of libraries we want. !sfn --$!libswanted='net socket inet nsl nm ndbm gdbm dbm db malloc dl' !sfn -+$!libswanted='net socket inet nm ndbm gdbm dbm db malloc dl' !sfn - $!libswanted="$libswanted ld sun m c cposix posix ndir dir crypt" !sfn - $!libswanted="$libswanted ucb bsd BSD PW x" !sfn - $!: We probably want to search /usr/shlib before most other libraries. !sfn -Only in perl-5.30.0/: configure.com.orig -Only in perl-5.30.0/: Configure.orig -diff -ur perl-5.30.0.orig/cpan/Config-Perl-V/t/20_plv56.t perl-5.30.0/cpan/Config-Perl-V/t/20_plv56.t ---- perl-5.30.0.orig/cpan/Config-Perl-V/t/20_plv56.t 2019-05-11 05:50:20.000000000 -0400 -+++ perl-5.30.0/cpan/Config-Perl-V/t/20_plv56.t 2019-10-14 17:35:46.612063373 -0400 -@@ -63,8 +63,8 @@ - Linker and Libraries: - ld='cc', ldflags ='-L/pro/local/lib' - libpth=/pro/local/lib /lib /usr/lib /usr/local/lib -- libs=-lnsl -lgdbm -ldb -ldl -lm -lc -lcrypt -lutil -- perllibs=-lnsl -ldl -lm -lc -lcrypt -lutil -+ libs=-lgdbm -ldb -ldl -lm -lc -lcrypt -lutil -+ perllibs=-ldl -lm -lc -lcrypt -lutil - libc=/lib/libc-2.10.1.so, so=so, useshrplib=false, libperl=libperl.a - Dynamic Linking: - dlsrc=dl_dlopen.xs, dlext=so, d_dlsymun=undef, ccdlflags='-rdynamic' -Only in perl-5.30.0/cpan/Config-Perl-V/t: 20_plv56.t.orig -diff -ur perl-5.30.0.orig/cpan/Config-Perl-V/t/21_plv58.t perl-5.30.0/cpan/Config-Perl-V/t/21_plv58.t ---- perl-5.30.0.orig/cpan/Config-Perl-V/t/21_plv58.t 2019-05-11 05:50:20.000000000 -0400 -+++ perl-5.30.0/cpan/Config-Perl-V/t/21_plv58.t 2019-10-14 17:35:46.612063373 -0400 -@@ -67,8 +67,8 @@ - Linker and Libraries: - ld='cc', ldflags ='-L/pro/local/lib' - libpth=/pro/local/lib /lib /usr/lib /usr/local/lib -- libs=-lnsl -lgdbm -ldb -ldl -lm -lcrypt -lutil -lpthread -lc -- perllibs=-lnsl -ldl -lm -lcrypt -lutil -lpthread -lc -+ libs=-lgdbm -ldb -ldl -lm -lcrypt -lutil -lpthread -lc -+ perllibs=-ldl -lm -lcrypt -lutil -lpthread -lc - libc=/lib/libc-2.11.2.so, so=so, useshrplib=false, libperl=libperl.a - gnulibc_version='2.11.2' - Dynamic Linking: -Only in perl-5.30.0/cpan/Config-Perl-V/t: 21_plv58.t.orig -diff -ur perl-5.30.0.orig/cpan/Config-Perl-V/t/22_plv510.t perl-5.30.0/cpan/Config-Perl-V/t/22_plv510.t ---- perl-5.30.0.orig/cpan/Config-Perl-V/t/22_plv510.t 2019-05-11 05:50:20.000000000 -0400 -+++ perl-5.30.0/cpan/Config-Perl-V/t/22_plv510.t 2019-10-14 17:35:46.612063373 -0400 -@@ -57,8 +57,8 @@ - Linker and Libraries: - ld='cc', ldflags ='-L/pro/local/lib' - libpth=/pro/local/lib /lib /usr/lib /usr/local/lib -- libs=-lnsl -lgdbm -ldb -ldl -lm -lcrypt -lutil -lc -- perllibs=-lnsl -ldl -lm -lcrypt -lutil -lc -+ libs=-lgdbm -ldb -ldl -lm -lcrypt -lutil -lc -+ perllibs=-ldl -lm -lcrypt -lutil -lc - libc=/lib/libc-2.6.1.so, so=so, useshrplib=false, libperl=libperl.a - gnulibc_version='2.6.1' - Dynamic Linking: -Only in perl-5.30.0/cpan/Config-Perl-V/t: 22_plv510.t.orig -diff -ur perl-5.30.0.orig/cpan/Config-Perl-V/t/23_plv512.t perl-5.30.0/cpan/Config-Perl-V/t/23_plv512.t ---- perl-5.30.0.orig/cpan/Config-Perl-V/t/23_plv512.t 2019-05-11 05:50:20.000000000 -0400 -+++ perl-5.30.0/cpan/Config-Perl-V/t/23_plv512.t 2019-10-14 17:35:46.612063373 -0400 -@@ -68,8 +68,8 @@ - Linker and Libraries: - ld='/usr/bin/ld', ldflags ='-L/pro/local/lib +DD64 -L/usr/lib/hpux64' - libpth=/pro/local/lib /usr/lib/hpux64 /lib /usr/lib /usr/ccs/lib /usr/local/lib -- libs=-lcl -lpthread -lnsl -lnm -ldb -ldl -ldld -lm -lsec -lc -- perllibs=-lcl -lpthread -lnsl -lnm -ldl -ldld -lm -lsec -lc -+ libs=-lcl -lpthread -lnm -ldb -ldl -ldld -lm -lsec -lc -+ perllibs=-lcl -lpthread -lnm -ldl -ldld -lm -lsec -lc - libc=/usr/lib/hpux64/libc.so, so=so, useshrplib=false, libperl=libperl.a - gnulibc_version='' - Dynamic Linking: -Only in perl-5.30.0/cpan/Config-Perl-V/t: 23_plv512.t.orig -diff -ur perl-5.30.0.orig/cpan/Config-Perl-V/t/24_plv514.t perl-5.30.0/cpan/Config-Perl-V/t/24_plv514.t ---- perl-5.30.0.orig/cpan/Config-Perl-V/t/24_plv514.t 2019-05-11 05:50:20.000000000 -0400 -+++ perl-5.30.0/cpan/Config-Perl-V/t/24_plv514.t 2019-10-14 17:35:46.612063373 -0400 -@@ -69,8 +69,8 @@ - Linker and Libraries: - ld='ld', ldflags ='-L/usr/local/ppc64/lib64 -b64 -q64 -L/pro/local/lib -brtl -bdynamic -b64' - libpth=/usr/local/ppc64/lib64 /lib /usr/lib /usr/ccs/lib /usr/local/lib /usr/lib64 -- libs=-lbind -lnsl -ldbm -ldb -ldl -lld -lm -lcrypt -lc -- perllibs=-lbind -lnsl -ldl -lld -lm -lcrypt -lc -+ libs=-lbind -ldbm -ldb -ldl -lld -lm -lcrypt -lc -+ perllibs=-lbind -ldl -lld -lm -lcrypt -lc - libc=/lib/libc.a, so=a, useshrplib=false, libperl=libperl.a - gnulibc_version='' - Dynamic Linking: -Only in perl-5.30.0/cpan/Config-Perl-V/t: 24_plv514.t.orig -diff -ur perl-5.30.0.orig/cpan/Config-Perl-V/t/25_plv516.t perl-5.30.0/cpan/Config-Perl-V/t/25_plv516.t ---- perl-5.30.0.orig/cpan/Config-Perl-V/t/25_plv516.t 2019-05-11 05:50:20.000000000 -0400 -+++ perl-5.30.0/cpan/Config-Perl-V/t/25_plv516.t 2019-10-14 17:35:46.612063373 -0400 -@@ -69,8 +69,8 @@ - Linker and Libraries: - ld='cc', ldflags ='-L/pro/local/lib -fstack-protector' - libpth=/pro/local/lib /lib /usr/lib /usr/local/lib -- libs=-lnsl -lgdbm -ldb -ldl -lm -lcrypt -lutil -lc -lgdbm_compat -- perllibs=-lnsl -ldl -lm -lcrypt -lutil -lc -+ libs=-lgdbm -ldb -ldl -lm -lcrypt -lutil -lc -lgdbm_compat -+ perllibs=-ldl -lm -lcrypt -lutil -lc - libc=/lib/libc-2.15.so, so=so, useshrplib=false, libperl=libperl.a - gnulibc_version='2.15' - Dynamic Linking: -Only in perl-5.30.0/cpan/Config-Perl-V/t: 25_plv516.t.orig -diff -ur perl-5.30.0.orig/cpan/Config-Perl-V/t/26_plv5182.t perl-5.30.0/cpan/Config-Perl-V/t/26_plv5182.t ---- perl-5.30.0.orig/cpan/Config-Perl-V/t/26_plv5182.t 2019-05-11 05:50:20.000000000 -0400 -+++ perl-5.30.0/cpan/Config-Perl-V/t/26_plv5182.t 2019-10-14 17:35:46.612063373 -0400 -@@ -94,8 +94,8 @@ - Linker and Libraries: - ld='cc', ldflags ='-L/pro/local/lib -fstack-protector' - libpth=/pro/local/lib /lib /usr/lib /usr/local/lib -- libs=-lnsl -lgdbm -ldb -ldl -lm -lcrypt -lutil -lc -lgdbm_compat -- perllibs=-lnsl -ldl -lm -lcrypt -lutil -lc -+ libs=-lgdbm -ldb -ldl -lm -lcrypt -lutil -lc -lgdbm_compat -+ perllibs=-ldl -lm -lcrypt -lutil -lc - libc=/lib/libc-2.18.so, so=so, useshrplib=false, libperl=libperl.a - gnulibc_version='2.18' - Dynamic Linking: -Only in perl-5.30.0/cpan/Config-Perl-V/t: 26_plv5182.t.orig -diff -ur perl-5.30.0.orig/cpan/Config-Perl-V/t/26_plv518.t perl-5.30.0/cpan/Config-Perl-V/t/26_plv518.t ---- perl-5.30.0.orig/cpan/Config-Perl-V/t/26_plv518.t 2019-05-11 05:50:20.000000000 -0400 -+++ perl-5.30.0/cpan/Config-Perl-V/t/26_plv518.t 2019-10-14 17:35:46.616063181 -0400 -@@ -94,8 +94,8 @@ - Linker and Libraries: - ld='cc', ldflags ='-L/pro/local/lib -fstack-protector' - libpth=/pro/local/lib /lib /usr/lib /usr/local/lib -- libs=-lnsl -lgdbm -ldb -ldl -lm -lcrypt -lutil -lc -lgdbm_compat -- perllibs=-lnsl -ldl -lm -lcrypt -lutil -lc -+ libs=-lgdbm -ldb -ldl -lm -lcrypt -lutil -lc -lgdbm_compat -+ perllibs=-ldl -lm -lcrypt -lutil -lc - libc=/lib/libc-2.17.so, so=so, useshrplib=false, libperl=libperl.a - gnulibc_version='2.17' - Dynamic Linking: -Only in perl-5.30.0/cpan/Config-Perl-V/t: 26_plv518.t.orig -diff -ur perl-5.30.0.orig/cpan/Config-Perl-V/t/27_plv5200.t perl-5.30.0/cpan/Config-Perl-V/t/27_plv5200.t ---- perl-5.30.0.orig/cpan/Config-Perl-V/t/27_plv5200.t 2019-05-11 05:50:20.000000000 -0400 -+++ perl-5.30.0/cpan/Config-Perl-V/t/27_plv5200.t 2019-10-14 17:35:46.620062988 -0400 -@@ -96,8 +96,8 @@ - Linker and Libraries: - ld='cc', ldflags ='-L/pro/local/lib -fstack-protector' - libpth=/usr/local/lib /usr/lib/gcc/i586-suse-linux/4.8/include-fixed /usr/lib/gcc/i586-suse-linux/4.8/../../../../i586-suse-linux/lib /usr/lib /pro/local/lib /lib -- libs=-lnsl -lgdbm -ldb -ldl -lm -lcrypt -lutil -lpthread -lc -lgdbm_compat -- perllibs=-lnsl -ldl -lm -lcrypt -lutil -lpthread -lc -+ libs=-lgdbm -ldb -ldl -lm -lcrypt -lutil -lpthread -lc -lgdbm_compat -+ perllibs=-ldl -lm -lcrypt -lutil -lpthread -lc - libc=libc-2.18.so, so=so, useshrplib=false, libperl=libperl.a - gnulibc_version='2.18' - Dynamic Linking: -Only in perl-5.30.0/cpan/Config-Perl-V/t: 27_plv5200.t.orig -diff -ur perl-5.30.0.orig/Cross/config.sh-arm-linux perl-5.30.0/Cross/config.sh-arm-linux ---- perl-5.30.0.orig/Cross/config.sh-arm-linux 2019-05-11 05:50:20.000000000 -0400 -+++ perl-5.30.0/Cross/config.sh-arm-linux 2019-10-14 17:35:46.620062988 -0400 -@@ -866,12 +866,12 @@ - libc='/lib/libc-2.2.2.so' - libperl='libperl.so' - libpth='/usr/local/lib /lib /usr/lib' --libs='-lnsl -ldl -lm -lcrypt -lutil -lc' -+libs='-ldl -lm -lcrypt -lutil -lc' - libsdirs=' /usr/lib' --libsfiles=' libnsl.so libdl.so libm.so libcrypt.so libutil.so libc.so' --libsfound=' /usr/lib/libnsl.so /usr/lib/libdl.so /usr/lib/libm.so /usr/lib/libcrypt.so /usr/lib/libutil.so /usr/lib/libc.so' -+libsfiles=' libdl.so libm.so libcrypt.so libutil.so libc.so' -+libsfound=' /usr/lib/libdl.so /usr/lib/libm.so /usr/lib/libcrypt.so /usr/lib/libutil.so /usr/lib/libc.so' - libspath=' /usr/local/lib /lib /usr/lib' --libswanted='socket bind inet nsl nm ndbm gdbm dbm db malloc dl ld sun m crypt sec util c cposix posix ucb BSD' -+libswanted='socket bind inet nm ndbm gdbm dbm db malloc dl ld sun m crypt sec util c cposix posix ucb BSD' - libswanted_uselargefiles='' - line='' - lint='' -@@ -959,7 +959,7 @@ - perl_patchlevel='' - perl_static_inline='static' - perladmin='red@criticalintegration.com' --perllibs='-lnsl -ldl -lm -lcrypt -lutil -lc' -+perllibs='-ldl -lm -lcrypt -lutil -lc' - perlpath='/usr/bin/perl' - pg='pg' - phostname='hostname' -diff -ur perl-5.30.0.orig/Cross/config.sh-arm-linux-n770 perl-5.30.0/Cross/config.sh-arm-linux-n770 ---- perl-5.30.0.orig/Cross/config.sh-arm-linux-n770 2019-05-11 05:50:20.000000000 -0400 -+++ perl-5.30.0/Cross/config.sh-arm-linux-n770 2019-10-14 17:35:46.620062988 -0400 -@@ -864,12 +864,12 @@ - libc='/lib/libc-2.2.2.so' - libperl='libperl.arma' - libpth='/usr/local/lib /lib /usr/lib' --libs='-lnsl -ldl -lm -lcrypt -lutil -lc' -+libs='-ldl -lm -lcrypt -lutil -lc' - libsdirs=' /usr/lib' --libsfiles=' libnsl.so libdl.so libm.so libcrypt.so libutil.so libc.so' --libsfound=' /usr/lib/libnsl.so /usr/lib/libdl.so /usr/lib/libm.so /usr/lib/libcrypt.so /usr/lib/libutil.so /usr/lib/libc.so' -+libsfiles=' libdl.so libm.so libcrypt.so libutil.so libc.so' -+libsfound=' /usr/lib/libdl.so /usr/lib/libm.so /usr/lib/libcrypt.so /usr/lib/libutil.so /usr/lib/libc.so' - libspath=' /usr/local/lib /lib /usr/lib' --libswanted='socket bind inet nsl nm ndbm gdbm dbm db malloc dl ld sun m crypt sec util c cposix posix ucb BSD' -+libswanted='socket bind inet nm ndbm gdbm dbm db malloc dl ld sun m crypt sec util c cposix posix ucb BSD' - libswanted_uselargefiles='' - line='' - lint='' -@@ -957,7 +957,7 @@ - perl_patchlevel='' - perl_static_inline='static' - perladmin='red@criticalintegration.com' --perllibs='-lnsl -ldl -lm -lcrypt -lutil -lc' -+perllibs='-ldl -lm -lcrypt -lutil -lc' - perlpath='/usr/bin/perl' - pg='pg' - phostname='hostname' -Only in perl-5.30.0/Cross: config.sh-arm-linux-n770.orig -Only in perl-5.30.0/Cross: config.sh-arm-linux.orig -diff -ur perl-5.30.0.orig/hints/aix_4.sh perl-5.30.0/hints/aix_4.sh ---- perl-5.30.0.orig/hints/aix_4.sh 2018-06-27 07:17:56.000000000 -0400 -+++ perl-5.30.0/hints/aix_4.sh 2019-10-14 17:35:46.620062988 -0400 -@@ -583,7 +583,7 @@ - - *** - *** You seem to be compiling in AIX for the OS/400 PASE environment. --*** I'm not going to use the AIX bind, nsl, and possible util libraries, then. -+*** I'm not going to use the AIX bind, and possible util libraries, then. - *** I'm also not going to install perl as /usr/bin/perl. - *** Perl will be installed under $prefix. - *** For instructions how to install this build from AIX to PASE, -@@ -591,7 +591,7 @@ - *** about "Operating system name". - *** - EOF -- set `echo " $libswanted " | sed -e 's@ bind @ @' -e 's@ nsl @ @' -e 's@ util @ @'` -+ set `echo " $libswanted " | sed -e 's@ bind @ @' -e 's@ util @ @'` - shift - libswanted="$*" - installusrbinperl="$undef" -diff -ur perl-5.30.0.orig/hints/aix.sh perl-5.30.0/hints/aix.sh ---- perl-5.30.0.orig/hints/aix.sh 2019-05-11 05:50:20.000000000 -0400 -+++ perl-5.30.0/hints/aix.sh 2019-10-14 17:35:46.620062988 -0400 -@@ -504,7 +504,7 @@ - - *** - *** You seem to be compiling in AIX for the OS/400 PASE environment. --*** I'm not going to use the AIX bind, nsl, and possible util libraries, then. -+*** I'm not going to use the AIX bind, and possible util libraries, then. - *** I'm also not going to install perl as /usr/bin/perl. - *** Perl will be installed under $prefix. - *** For instructions how to install this build from AIX to PASE, -@@ -512,7 +512,7 @@ - *** about "Operating system name". - *** - EOF -- set `echo " $libswanted " | sed -e 's@ bind @ @' -e 's@ nsl @ @' -e 's@ util @ @'` -+ set `echo " $libswanted " | sed -e 's@ bind @ @' -e 's@ util @ @'` - shift - libswanted="$*" - installusrbinperl="$undef" -diff -ur perl-5.30.0.orig/hints/epix.sh perl-5.30.0/hints/epix.sh ---- perl-5.30.0.orig/hints/epix.sh 2019-05-11 05:50:20.000000000 -0400 -+++ perl-5.30.0/hints/epix.sh 2019-10-14 17:35:46.620062988 -0400 -@@ -37,7 +37,7 @@ - # Old version had this, but I'm not sure why since the old version - # also mucked around with libswanted. This is also definitely wrong - # if the user is trying to use DB_File or GDBM_File. --# libs='-lsocket -lnsl -ldbm -ldl -lc -lcrypt -lm -lucb' -+# libs='-lsocket -ldbm -ldl -lc -lcrypt -lm -lucb' - - # We include support for using libraries in /usr/ucblib, but the setting - # of libswanted excludes some libraries found there. You may want to -diff -ur perl-5.30.0.orig/hints/gnu.sh perl-5.30.0/hints/gnu.sh ---- perl-5.30.0.orig/hints/gnu.sh 2019-05-11 05:50:20.000000000 -0400 -+++ perl-5.30.0/hints/gnu.sh 2019-10-14 17:35:46.620062988 -0400 -@@ -3,7 +3,7 @@ - - # libnsl is unusable on the Hurd. - # XXX remove this once SUNRPC is implemented. --set `echo X "$libswanted "| sed -e 's/ bsd / /' -e 's/ nsl / /' -e 's/ c / pthread /'` -+set `echo X "$libswanted "| sed -e 's/ bsd / /' -e 's/ c / pthread /'` - shift - libswanted="$*" - -Only in perl-5.30.0/hints: gnu.sh.orig -diff -ur perl-5.30.0.orig/hints/irix_5.sh perl-5.30.0/hints/irix_5.sh ---- perl-5.30.0.orig/hints/irix_5.sh 2018-06-27 07:17:56.000000000 -0400 -+++ perl-5.30.0/hints/irix_5.sh 2019-10-14 17:35:46.624062797 -0400 -@@ -27,9 +27,9 @@ - esac - - lddlflags="-shared" --# For some reason we don't want -lsocket -lnsl or -ldl. Can anyone -+# For some reason we don't want -lsocket or -ldl. Can anyone - # contribute an explanation? --set `echo X "$libswanted "|sed -e 's/ socket / /' -e 's/ nsl / /' -e 's/ dl / /'` -+set `echo X "$libswanted "|sed -e 's/ socket / /' -e 's/ dl / /'` - shift - libswanted="$*" - -diff -ur perl-5.30.0.orig/hints/irix_6_0.sh perl-5.30.0/hints/irix_6_0.sh ---- perl-5.30.0.orig/hints/irix_6_0.sh 2018-06-27 07:17:56.000000000 -0400 -+++ perl-5.30.0/hints/irix_6_0.sh 2019-10-14 17:35:46.624062797 -0400 -@@ -19,7 +19,7 @@ - lddlflags="-32 -shared" - - # We don't want these libraries. Anyone know why? --set `echo X "$libswanted "|sed -e 's/ socket / /' -e 's/ nsl / /' -e 's/ dl / /'` -+set `echo X "$libswanted "|sed -e 's/ socket / /' -e 's/ dl / /'` - shift - libswanted="$*" - # -@@ -29,7 +29,7 @@ - # taken from irix_5.sh . Changes from irix_5.sh: - # Olimit and nested comments (warning 1009) no longer accepted - # -OPT:fold_arith_limit so POSIX module will optimize --# no 64bit versions of sun, crypt, nsl, socket, dl dso's available -+# no 64bit versions of sun, crypt, socket, dl dso's available - # as of IRIX 6.0.1 so omit those from libswanted line via `sed'. - - # perl 5 built with this hints file passes most tests (`make test'). -@@ -38,7 +38,7 @@ - # i_time='define' - # ccflags="$ccflags -D_POSIX_SOURCE -ansiposix -D_BSD_TYPES -woff 1009 -OPT:fold_arith_limit=1046" - # lddlflags="-shared" --# set `echo X "$libswanted "|sed -e 's/ socket / /' -e 's/ sun / /' -e 's/ crypt / /' -e 's/ nsl / /' -e 's/ dl / /'` -+# set `echo X "$libswanted "|sed -e 's/ socket / /' -e 's/ sun / /' -e 's/ crypt / /' -e 's/ dl / /'` - # shift - # libswanted="$*" - -diff -ur perl-5.30.0.orig/hints/irix_6_1.sh perl-5.30.0/hints/irix_6_1.sh ---- perl-5.30.0.orig/hints/irix_6_1.sh 2018-06-27 07:17:56.000000000 -0400 -+++ perl-5.30.0/hints/irix_6_1.sh 2019-10-14 17:35:46.624062797 -0400 -@@ -19,7 +19,7 @@ - lddlflags="-32 -shared" - - # We don't want these libraries. Anyone know why? --set `echo X "$libswanted "|sed -e 's/ socket / /' -e 's/ nsl / /' -e 's/ dl / /'` -+set `echo X "$libswanted "|sed -e 's/ socket / /' -e 's/ dl / /'` - shift - libswanted="$*" - # -@@ -29,7 +29,7 @@ - # taken from irix_5.sh . Changes from irix_5.sh: - # Olimit and nested comments (warning 1009) no longer accepted - # -OPT:fold_arith_limit so POSIX module will optimize --# no 64bit versions of sun, crypt, nsl, socket, dl dso's available -+# no 64bit versions of sun, crypt, socket, dl dso's available - # as of IRIX 6.0.1 so omit those from libswanted line via `sed'. - - # perl 5 built with this hints file passes most tests (`make test'). -@@ -38,7 +38,7 @@ - # i_time='define' - # ccflags="$ccflags -D_POSIX_SOURCE -ansiposix -D_BSD_TYPES -woff 1009 -OPT:fold_arith_limit=1046" - # lddlflags="-shared" --# set `echo X "$libswanted "|sed -e 's/ socket / /' -e 's/ sun / /' -e 's/ crypt / /' -e 's/ nsl / /' -e 's/ dl / /'` -+# set `echo X "$libswanted "|sed -e 's/ socket / /' -e 's/ sun / /' -e 's/ crypt / /' -e 's/ dl / /'` - # shift - # libswanted="$*" - -diff -ur perl-5.30.0.orig/hints/irix_6.sh perl-5.30.0/hints/irix_6.sh ---- perl-5.30.0.orig/hints/irix_6.sh 2019-05-11 05:50:20.000000000 -0400 -+++ perl-5.30.0/hints/irix_6.sh 2019-10-14 17:35:46.624062797 -0400 -@@ -388,7 +388,7 @@ - # Socket networking is in libc, these are not installed by default, - # and just slow perl down. (scotth@sgi.com) - # librt contains nothing we need (some places need it for Time::HiRes) --jhi --set `echo X "$libswanted "|sed -e 's/ socket / /' -e 's/ nsl / /' -e 's/ dl / /' -e 's/ rt / /'` -+set `echo X "$libswanted "|sed -e 's/ socket / /' -e 's/ dl / /' -e 's/ rt / /'` - shift - libswanted="$*" - -diff -ur perl-5.30.0.orig/INSTALL perl-5.30.0/INSTALL ---- perl-5.30.0.orig/INSTALL 2019-05-11 05:50:20.000000000 -0400 -+++ perl-5.30.0/INSTALL 2019-10-14 17:36:13.034898813 -0400 -@@ -1623,7 +1623,7 @@ - undefined symbols, check the libs variable in the config.sh file. It - should look something like - -- libs='-lsocket -lnsl -ldl -lm -lc' -+ libs='-lsocket -ldl -lm -lc' - - The exact libraries will vary from system to system, but you typically - need to include at least the math library -lm. Normally, Configure -Only in perl-5.30.0/: INSTALL.orig -diff -ur perl-5.30.0.orig/NetWare/config.wc perl-5.30.0/NetWare/config.wc ---- perl-5.30.0.orig/NetWare/config.wc 2019-05-11 05:50:20.000000000 -0400 -+++ perl-5.30.0/NetWare/config.wc 2019-10-14 17:36:13.034898813 -0400 -@@ -846,7 +846,7 @@ - libsfiles='' - libsfound='' - libspath='' --libswanted='net socket inet nsl nm ndbm gdbm dbm db malloc dl ld sun m c cposix posix ndir dir crypt ucb bsd BSD PW x' -+libswanted='net socket inet nm ndbm gdbm dbm db malloc dl ld sun m c cposix posix ndir dir crypt ucb bsd BSD PW x' - line='line' - lint='' - lkflags='' -Only in perl-5.30.0/NetWare: config.wc.orig -diff -ur perl-5.30.0.orig/plan9/config_sh.sample perl-5.30.0/plan9/config_sh.sample ---- perl-5.30.0.orig/plan9/config_sh.sample 2019-05-11 05:50:20.000000000 -0400 -+++ perl-5.30.0/plan9/config_sh.sample 2019-10-14 17:36:13.038898652 -0400 -@@ -853,7 +853,7 @@ - libsfiles='' - libsfound='' - libspath=' /lib' --libswanted='socket bind inet nsl nm ndbm gdbm dbm db malloc dl ld sun m c cposix posix ndir dir crypt sec ucb bsd BSD PW x util' -+libswanted='socket bind inet nm ndbm gdbm dbm db malloc dl ld sun m c cposix posix ndir dir crypt sec ucb bsd BSD PW x util' - libswanted_uselargefiles='' - line='' - lint='' -Only in perl-5.30.0/plan9: config_sh.sample.orig -diff -ur perl-5.30.0.orig/pod/perlrun.pod perl-5.30.0/pod/perlrun.pod ---- perl-5.30.0.orig/pod/perlrun.pod 2019-05-11 05:50:20.000000000 -0400 -+++ perl-5.30.0/pod/perlrun.pod 2019-10-14 17:36:13.038898652 -0400 -@@ -887,11 +887,11 @@ - $ perl -V:libc - libc='/lib/libc-2.2.4.so'; - $ perl -V:lib. -- libs='-lnsl -lgdbm -ldb -ldl -lm -lcrypt -lutil -lc'; -+ libs='-lgdbm -ldb -ldl -lm -lcrypt -lutil -lc'; - libc='/lib/libc-2.2.4.so'; - $ perl -V:lib.* - libpth='/usr/local/lib /lib /usr/lib'; -- libs='-lnsl -lgdbm -ldb -ldl -lm -lcrypt -lutil -lc'; -+ libs='-lgdbm -ldb -ldl -lm -lcrypt -lutil -lc'; - lib_ext='.a'; - libc='/lib/libc-2.2.4.so'; - libperl='libperl.a'; -Only in perl-5.30.0/pod: perlrun.pod.orig -diff -ur perl-5.30.0.orig/Porting/bisect-runner.pl perl-5.30.0/Porting/bisect-runner.pl ---- perl-5.30.0.orig/Porting/bisect-runner.pl 2019-05-11 05:50:20.000000000 -0400 -+++ perl-5.30.0/Porting/bisect-runner.pl 2019-10-14 17:36:13.038898652 -0400 -@@ -1384,7 +1384,7 @@ - my @libs; - # This is the current libswanted list from Configure, less the libs removed - # by current hints/linux.sh -- foreach my $lib (qw(sfio socket inet nsl nm ndbm gdbm dbm db malloc dl -+ foreach my $lib (qw(sfio socket inet nm ndbm gdbm dbm db malloc dl - ld sun m crypt sec util c cposix posix ucb BSD)) { - foreach my $dir (@paths) { - # Note the wonderful consistency of dot-or-not in the config vars: -Only in perl-5.30.0/Porting: bisect-runner.pl.orig -diff -ur perl-5.30.0.orig/Porting/config.sh perl-5.30.0/Porting/config.sh ---- perl-5.30.0.orig/Porting/config.sh 2019-05-11 05:50:20.000000000 -0400 -+++ perl-5.30.0/Porting/config.sh 2019-10-14 17:38:20.815713492 -0400 -@@ -891,12 +891,12 @@ - libc='libc-2.19.so' - libperl='libperl.a' - libpth='/usr/local/lib /usr/lib/gcc/x86_64-linux-gnu/4.9/include-fixed /usr/include/x86_64-linux-gnu /usr/lib /lib/x86_64-linux-gnu /lib/../lib /usr/lib/x86_64-linux-gnu /usr/lib/../lib /lib' --libs='-lpthread -lnsl -lgdbm -ldb -ldl -lm -lcrypt -lutil -lc -lgdbm_compat' -+libs='-lpthread -lgdbm -ldb -ldl -lm -lcrypt -lutil -lc -lgdbm_compat' - libsdirs=' /usr/lib/x86_64-linux-gnu' --libsfiles=' libpthread.so libnsl.so libgdbm.so libdb.so libdl.so libm.so libcrypt.so libutil.so libc.so libgdbm_compat.so' --libsfound=' /usr/lib/x86_64-linux-gnu/libpthread.so /usr/lib/x86_64-linux-gnu/libnsl.so /usr/lib/x86_64-linux-gnu/libgdbm.so /usr/lib/x86_64-linux-gnu/libdb.so /usr/lib/x86_64-linux-gnu/libdl.so /usr/lib/x86_64-linux-gnu/libm.so /usr/lib/x86_64-linux-gnu/libcrypt.so /usr/lib/x86_64-linux-gnu/libutil.so /usr/lib/x86_64-linux-gnu/libc.so /usr/lib/x86_64-linux-gnu/libgdbm_compat.so' -+libsfiles=' libpthread.so libgdbm.so libdb.so libdl.so libm.so libcrypt.so libutil.so libc.so libgdbm_compat.so' -+libsfound=' /usr/lib/x86_64-linux-gnu/libpthread.so /usr/lib/x86_64-linux-gnu/libgdbm.so /usr/lib/x86_64-linux-gnu/libdb.so /usr/lib/x86_64-linux-gnu/libdl.so /usr/lib/x86_64-linux-gnu/libm.so /usr/lib/x86_64-linux-gnu/libcrypt.so /usr/lib/x86_64-linux-gnu/libutil.so /usr/lib/x86_64-linux-gnu/libc.so /usr/lib/x86_64-linux-gnu/libgdbm_compat.so' - libspath=' /usr/local/lib /usr/lib/gcc/x86_64-linux-gnu/4.9/include-fixed /usr/include/x86_64-linux-gnu /usr/lib /lib/x86_64-linux-gnu /lib/../lib /usr/lib/x86_64-linux-gnu /usr/lib/../lib /lib' --libswanted='cl pthread cl pthread socket inet nsl gdbm dbm db malloc dl ld sun m crypt sec util c cposix posix ucb BSD gdbm_compat' -+libswanted='cl pthread cl pthread socket inet gdbm dbm db malloc dl ld sun m crypt sec util c cposix posix ucb BSD gdbm_compat' - libswanted_uselargefiles='' - line='' - lint='' -@@ -983,7 +983,7 @@ - perl_patchlevel='' - perl_static_inline='static __inline__' - perladmin='yourname@yourhost.yourplace.com' --perllibs='-lpthread -lnsl -ldl -lm -lcrypt -lutil -lc' -+perllibs='-lpthread -ldl -lm -lcrypt -lutil -lc' - perlpath='/opt/perl/bin/perl5.30.0' - pg='pg' - phostname='' -Only in perl-5.30.0/Porting: config.sh.orig -diff -ur perl-5.30.0.orig/win32/config.ce perl-5.30.0/win32/config.ce ---- perl-5.30.0.orig/win32/config.ce 2019-05-11 05:50:20.000000000 -0400 -+++ perl-5.30.0/win32/config.ce 2019-10-14 17:36:13.090896568 -0400 -@@ -839,7 +839,7 @@ - libsfiles='' - libsfound='' - libspath='' --libswanted='net socket inet nsl nm ndbm gdbm dbm db malloc dl ld sun m c cposix posix ndir dir crypt ucb bsd BSD PW x' -+libswanted='net socket inet nm ndbm gdbm dbm db malloc dl ld sun m c cposix posix ndir dir crypt ucb bsd BSD PW x' - line='line' - lint='' - lkflags='' -Only in perl-5.30.0/win32: config.ce.orig -diff -ur perl-5.30.0.orig/win32/config.gc perl-5.30.0/win32/config.gc ---- perl-5.30.0.orig/win32/config.gc 2019-05-11 05:50:20.000000000 -0400 -+++ perl-5.30.0/win32/config.gc 2019-10-14 17:36:13.090896568 -0400 -@@ -865,8 +865,8 @@ - libsfiles='' - libsfound='' - libspath='' --libswanted='net socket inet nsl nm ndbm gdbm dbm db malloc dl ld sun m c cposix posix ndir dir crypt ucb bsd BSD PW x' --libswanted_uselargefiles='net socket inet nsl nm ndbm gdbm dbm db malloc dl ld sun m c cposix posix ndir dir crypt ucb bsd BSD PW x' -+libswanted='net socket inet nm ndbm gdbm dbm db malloc dl ld sun m c cposix posix ndir dir crypt ucb bsd BSD PW x' -+libswanted_uselargefiles='net socket inet nm ndbm gdbm dbm db malloc dl ld sun m c cposix posix ndir dir crypt ucb bsd BSD PW x' - line='line' - lint='' - lkflags='' -Only in perl-5.30.0/win32: config.gc.orig -diff -ur perl-5.30.0.orig/win32/config.vc perl-5.30.0/win32/config.vc ---- perl-5.30.0.orig/win32/config.vc 2019-05-11 05:50:20.000000000 -0400 -+++ perl-5.30.0/win32/config.vc 2019-10-14 17:36:13.094896407 -0400 -@@ -864,8 +864,8 @@ - libsfiles='' - libsfound='' - libspath='' --libswanted='net socket inet nsl nm ndbm gdbm dbm db malloc dl ld sun m c cposix posix ndir dir crypt ucb bsd BSD PW x' --libswanted_uselargefiles='net socket inet nsl nm ndbm gdbm dbm db malloc dl ld sun m c cposix posix ndir dir crypt ucb bsd BSD PW x' -+libswanted='net socket inet nm ndbm gdbm dbm db malloc dl ld sun m c cposix posix ndir dir crypt ucb bsd BSD PW x' -+libswanted_uselargefiles='net socket inet nm ndbm gdbm dbm db malloc dl ld sun m c cposix posix ndir dir crypt ucb bsd BSD PW x' - line='line' - lint='' - lkflags='' -Only in perl-5.30.0/win32: config.vc.orig diff --git a/omnibus/config/patches/perl/perl-5.32.1-remove_lnsl.patch b/omnibus/config/patches/perl/perl-5.32.1-remove_lnsl.patch deleted file mode 100644 index fdc63aa0b..000000000 --- a/omnibus/config/patches/perl/perl-5.32.1-remove_lnsl.patch +++ /dev/null @@ -1,456 +0,0 @@ -diff --git a/Configure b/Configure -index fbc2258..14d9eba 100755 ---- a/Configure -+++ b/Configure -@@ -1491,7 +1491,7 @@ archname='' - usereentrant='undef' - : List of libraries we want. - : If anyone needs extra -lxxx, put those in a hint file. --libswanted="cl pthread socket bind inet nsl ndbm gdbm dbm db malloc dl ld" -+libswanted="cl pthread socket bind inet ndbm gdbm dbm db malloc dl ld" - libswanted="$libswanted sun m crypt sec util c cposix posix ucb bsd BSD" - : We probably want to search /usr/shlib before most other libraries. - : This is only used by the lib/ExtUtils/MakeMaker.pm routine extliblist. -diff --git a/Cross/config.sh-arm-linux b/Cross/config.sh-arm-linux -index d97a698..0eec85e 100644 ---- a/Cross/config.sh-arm-linux -+++ b/Cross/config.sh-arm-linux -@@ -869,12 +869,12 @@ lib_ext='.a' - libc='/lib/libc-2.2.2.so' - libperl='libperl.so' - libpth='/usr/local/lib /lib /usr/lib' --libs='-lnsl -ldl -lm -lcrypt -lutil -lc' -+libs='-ldl -lm -lcrypt -lutil -lc' - libsdirs=' /usr/lib' --libsfiles=' libnsl.so libdl.so libm.so libcrypt.so libutil.so libc.so' --libsfound=' /usr/lib/libnsl.so /usr/lib/libdl.so /usr/lib/libm.so /usr/lib/libcrypt.so /usr/lib/libutil.so /usr/lib/libc.so' -+libsfiles=' libdl.so libm.so libcrypt.so libutil.so libc.so' -+libsfound=' /usr/lib/libdl.so /usr/lib/libm.so /usr/lib/libcrypt.so /usr/lib/libutil.so /usr/lib/libc.so' - libspath=' /usr/local/lib /lib /usr/lib' --libswanted='socket bind inet nsl nm ndbm gdbm dbm db malloc dl ld sun m crypt sec util c cposix posix ucb BSD' -+libswanted='socket bind inet nm ndbm gdbm dbm db malloc dl ld sun m crypt sec util c cposix posix ucb BSD' - libswanted_uselargefiles='' - line='' - lint='' -@@ -962,7 +962,7 @@ perl='' - perl_patchlevel='' - perl_static_inline='static' - perladmin='red@criticalintegration.com' --perllibs='-lnsl -ldl -lm -lcrypt -lutil -lc' -+perllibs='-ldl -lm -lcrypt -lutil -lc' - perlpath='/usr/bin/perl' - pg='pg' - phostname='hostname' -diff --git a/Cross/config.sh-arm-linux-n770 b/Cross/config.sh-arm-linux-n770 -index 3ad709f..b3752bb 100644 ---- a/Cross/config.sh-arm-linux-n770 -+++ b/Cross/config.sh-arm-linux-n770 -@@ -867,12 +867,12 @@ lib_ext='.arma' - libc='/lib/libc-2.2.2.so' - libperl='libperl.arma' - libpth='/usr/local/lib /lib /usr/lib' --libs='-lnsl -ldl -lm -lcrypt -lutil -lc' -+libs='-ldl -lm -lcrypt -lutil -lc' - libsdirs=' /usr/lib' --libsfiles=' libnsl.so libdl.so libm.so libcrypt.so libutil.so libc.so' --libsfound=' /usr/lib/libnsl.so /usr/lib/libdl.so /usr/lib/libm.so /usr/lib/libcrypt.so /usr/lib/libutil.so /usr/lib/libc.so' -+libsfiles=' libdl.so libm.so libcrypt.so libutil.so libc.so' -+libsfound=' /usr/lib/libdl.so /usr/lib/libm.so /usr/lib/libcrypt.so /usr/lib/libutil.so /usr/lib/libc.so' - libspath=' /usr/local/lib /lib /usr/lib' --libswanted='socket bind inet nsl nm ndbm gdbm dbm db malloc dl ld sun m crypt sec util c cposix posix ucb BSD' -+libswanted='socket bind inet nm ndbm gdbm dbm db malloc dl ld sun m crypt sec util c cposix posix ucb BSD' - libswanted_uselargefiles='' - line='' - lint='' -@@ -960,7 +960,7 @@ perl='' - perl_patchlevel='' - perl_static_inline='static' - perladmin='red@criticalintegration.com' --perllibs='-lnsl -ldl -lm -lcrypt -lutil -lc' -+perllibs='-ldl -lm -lcrypt -lutil -lc' - perlpath='/usr/bin/perl' - pg='pg' - phostname='hostname' -diff --git a/INSTALL b/INSTALL -index 76edeec..6a039a2 100644 ---- a/INSTALL -+++ b/INSTALL -@@ -1629,7 +1629,7 @@ If the build of miniperl fails with a long list of missing functions or - undefined symbols, check the libs variable in the config.sh file. It - should look something like - -- libs='-lsocket -lnsl -ldl -lm -lc' -+ libs='-lsocket -ldl -lm -lc' - - The exact libraries will vary from system to system, but you typically - need to include at least the math library -lm. Normally, Configure -diff --git a/NetWare/config.wc b/NetWare/config.wc -index b0a02f5..f699a65 100644 ---- a/NetWare/config.wc -+++ b/NetWare/config.wc -@@ -849,7 +849,7 @@ libsdirs='' - libsfiles='' - libsfound='' - libspath='' --libswanted='net socket inet nsl nm ndbm gdbm dbm db malloc dl ld sun m c cposix posix ndir dir crypt ucb bsd BSD PW x' -+libswanted='net socket inet nm ndbm gdbm dbm db malloc dl ld sun m c cposix posix ndir dir crypt ucb bsd BSD PW x' - line='line' - lint='' - lkflags='' -diff --git a/Porting/bisect-runner.pl b/Porting/bisect-runner.pl -index b6c75a9..33de0c0 100755 ---- a/Porting/bisect-runner.pl -+++ b/Porting/bisect-runner.pl -@@ -1550,7 +1550,7 @@ unless (extract_from_file('Configure', 'ignore_versioned_solibs')) { - my @libs; - # This is the current libswanted list from Configure, less the libs removed - # by current hints/linux.sh -- foreach my $lib (qw(sfio socket inet nsl nm ndbm gdbm dbm db malloc dl -+ foreach my $lib (qw(sfio socket inet nm ndbm gdbm dbm db malloc dl - ld sun m crypt sec util c cposix posix ucb BSD)) { - foreach my $dir (@paths) { - # Note the wonderful consistency of dot-or-not in the config vars: -diff --git a/Porting/config.sh b/Porting/config.sh -index 2d2287c..c8fab58 100644 ---- a/Porting/config.sh -+++ b/Porting/config.sh -@@ -894,12 +894,12 @@ lib_ext='.a' - libc='libc-2.19.so' - libperl='libperl.a' - libpth='/usr/local/lib /usr/lib/gcc/x86_64-linux-gnu/4.9/include-fixed /usr/include/x86_64-linux-gnu /usr/lib /lib/x86_64-linux-gnu /lib/../lib /usr/lib/x86_64-linux-gnu /usr/lib/../lib /lib' --libs='-lpthread -lnsl -lgdbm -ldb -ldl -lm -lcrypt -lutil -lc -lgdbm_compat' -+libs='-lpthread -lgdbm -ldb -ldl -lm -lcrypt -lutil -lc -lgdbm_compat' - libsdirs=' /usr/lib/x86_64-linux-gnu' --libsfiles=' libpthread.so libnsl.so libgdbm.so libdb.so libdl.so libm.so libcrypt.so libutil.so libc.so libgdbm_compat.so' --libsfound=' /usr/lib/x86_64-linux-gnu/libpthread.so /usr/lib/x86_64-linux-gnu/libnsl.so /usr/lib/x86_64-linux-gnu/libgdbm.so /usr/lib/x86_64-linux-gnu/libdb.so /usr/lib/x86_64-linux-gnu/libdl.so /usr/lib/x86_64-linux-gnu/libm.so /usr/lib/x86_64-linux-gnu/libcrypt.so /usr/lib/x86_64-linux-gnu/libutil.so /usr/lib/x86_64-linux-gnu/libc.so /usr/lib/x86_64-linux-gnu/libgdbm_compat.so' -+libsfiles=' libpthread.so libgdbm.so libdb.so libdl.so libm.so libcrypt.so libutil.so libc.so libgdbm_compat.so' -+libsfound=' /usr/lib/x86_64-linux-gnu/libpthread.so /usr/lib/x86_64-linux-gnu/libgdbm.so /usr/lib/x86_64-linux-gnu/libdb.so /usr/lib/x86_64-linux-gnu/libdl.so /usr/lib/x86_64-linux-gnu/libm.so /usr/lib/x86_64-linux-gnu/libcrypt.so /usr/lib/x86_64-linux-gnu/libutil.so /usr/lib/x86_64-linux-gnu/libc.so /usr/lib/x86_64-linux-gnu/libgdbm_compat.so' - libspath=' /usr/local/lib /usr/lib/gcc/x86_64-linux-gnu/4.9/include-fixed /usr/include/x86_64-linux-gnu /usr/lib /lib/x86_64-linux-gnu /lib/../lib /usr/lib/x86_64-linux-gnu /usr/lib/../lib /lib' --libswanted='cl pthread cl pthread socket inet nsl gdbm dbm db malloc dl ld sun m crypt sec util c cposix posix ucb BSD gdbm_compat' -+libswanted='cl pthread cl pthread socket inet gdbm dbm db malloc dl ld sun m crypt sec util c cposix posix ucb BSD gdbm_compat' - libswanted_uselargefiles='' - line='' - lint='' -@@ -986,7 +986,7 @@ perl='perl' - perl_patchlevel='' - perl_static_inline='static __inline__' - perladmin='yourname@yourhost.yourplace.com' --perllibs='-lpthread -lnsl -ldl -lm -lcrypt -lutil -lc' -+perllibs='-lpthread -ldl -lm -lcrypt -lutil -lc' - perlpath='/opt/perl/bin/perl5.32.1' - pg='pg' - phostname='' -diff --git a/configure.com b/configure.com -index 713e875..6273d5d 100644 ---- a/configure.com -+++ b/configure.com -@@ -117,7 +117,7 @@ $!: is prepended to libpth. This variable takes care of special !sfn - $!: machines, like the mips. Usually, it should be empty. !sfn - $!plibpth='' !sfn - $!: List of libraries we want. !sfn --$!libswanted='net socket inet nsl nm ndbm gdbm dbm db malloc dl' !sfn -+$!libswanted='net socket inet nm ndbm gdbm dbm db malloc dl' !sfn - $!libswanted="$libswanted ld sun m c cposix posix ndir dir crypt" !sfn - $!libswanted="$libswanted ucb bsd BSD PW x" !sfn - $!: We probably want to search /usr/shlib before most other libraries. !sfn -diff --git a/cpan/Config-Perl-V/t/20_plv56.t b/cpan/Config-Perl-V/t/20_plv56.t -index 252a162..5004c9a 100644 ---- a/cpan/Config-Perl-V/t/20_plv56.t -+++ b/cpan/Config-Perl-V/t/20_plv56.t -@@ -63,8 +63,8 @@ Summary of my perl5 (revision 5.0 version 6 subversion 2) configuration: - Linker and Libraries: - ld='cc', ldflags ='-L/pro/local/lib' - libpth=/pro/local/lib /lib /usr/lib /usr/local/lib -- libs=-lnsl -lgdbm -ldb -ldl -lm -lc -lcrypt -lutil -- perllibs=-lnsl -ldl -lm -lc -lcrypt -lutil -+ libs=-lgdbm -ldb -ldl -lm -lc -lcrypt -lutil -+ perllibs=-ldl -lm -lc -lcrypt -lutil - libc=/lib/libc-2.10.1.so, so=so, useshrplib=false, libperl=libperl.a - Dynamic Linking: - dlsrc=dl_dlopen.xs, dlext=so, d_dlsymun=undef, ccdlflags='-rdynamic' -diff --git a/cpan/Config-Perl-V/t/21_plv58.t b/cpan/Config-Perl-V/t/21_plv58.t -index b354e24..d747355 100644 ---- a/cpan/Config-Perl-V/t/21_plv58.t -+++ b/cpan/Config-Perl-V/t/21_plv58.t -@@ -67,8 +67,8 @@ Summary of my perl5 (revision 5 version 8 subversion 9) configuration: - Linker and Libraries: - ld='cc', ldflags ='-L/pro/local/lib' - libpth=/pro/local/lib /lib /usr/lib /usr/local/lib -- libs=-lnsl -lgdbm -ldb -ldl -lm -lcrypt -lutil -lpthread -lc -- perllibs=-lnsl -ldl -lm -lcrypt -lutil -lpthread -lc -+ libs=-lgdbm -ldb -ldl -lm -lcrypt -lutil -lpthread -lc -+ perllibs=-ldl -lm -lcrypt -lutil -lpthread -lc - libc=/lib/libc-2.11.2.so, so=so, useshrplib=false, libperl=libperl.a - gnulibc_version='2.11.2' - Dynamic Linking: -diff --git a/cpan/Config-Perl-V/t/22_plv510.t b/cpan/Config-Perl-V/t/22_plv510.t -index bec688c..4641d12 100644 ---- a/cpan/Config-Perl-V/t/22_plv510.t -+++ b/cpan/Config-Perl-V/t/22_plv510.t -@@ -57,8 +57,8 @@ Summary of my perl5 (revision 5 version 10 subversion 0) configuration: - Linker and Libraries: - ld='cc', ldflags ='-L/pro/local/lib' - libpth=/pro/local/lib /lib /usr/lib /usr/local/lib -- libs=-lnsl -lgdbm -ldb -ldl -lm -lcrypt -lutil -lc -- perllibs=-lnsl -ldl -lm -lcrypt -lutil -lc -+ libs=-lgdbm -ldb -ldl -lm -lcrypt -lutil -lc -+ perllibs=-ldl -lm -lcrypt -lutil -lc - libc=/lib/libc-2.6.1.so, so=so, useshrplib=false, libperl=libperl.a - gnulibc_version='2.6.1' - Dynamic Linking: -diff --git a/cpan/Config-Perl-V/t/23_plv512.t b/cpan/Config-Perl-V/t/23_plv512.t -index 03c69cb..47d7f97 100644 ---- a/cpan/Config-Perl-V/t/23_plv512.t -+++ b/cpan/Config-Perl-V/t/23_plv512.t -@@ -68,8 +68,8 @@ Summary of my perl5 (revision 5 version 12 subversion 2) configuration: - Linker and Libraries: - ld='/usr/bin/ld', ldflags ='-L/pro/local/lib +DD64 -L/usr/lib/hpux64' - libpth=/pro/local/lib /usr/lib/hpux64 /lib /usr/lib /usr/ccs/lib /usr/local/lib -- libs=-lcl -lpthread -lnsl -lnm -ldb -ldl -ldld -lm -lsec -lc -- perllibs=-lcl -lpthread -lnsl -lnm -ldl -ldld -lm -lsec -lc -+ libs=-lcl -lpthread -lnm -ldb -ldl -ldld -lm -lsec -lc -+ perllibs=-lcl -lpthread -lnm -ldl -ldld -lm -lsec -lc - libc=/usr/lib/hpux64/libc.so, so=so, useshrplib=false, libperl=libperl.a - gnulibc_version='' - Dynamic Linking: -diff --git a/cpan/Config-Perl-V/t/24_plv514.t b/cpan/Config-Perl-V/t/24_plv514.t -index 3377b41..fdd8046 100644 ---- a/cpan/Config-Perl-V/t/24_plv514.t -+++ b/cpan/Config-Perl-V/t/24_plv514.t -@@ -69,8 +69,8 @@ Summary of my perl5 (revision 5 version 14 subversion 2) configuration: - Linker and Libraries: - ld='ld', ldflags ='-L/usr/local/ppc64/lib64 -b64 -q64 -L/pro/local/lib -brtl -bdynamic -b64' - libpth=/usr/local/ppc64/lib64 /lib /usr/lib /usr/ccs/lib /usr/local/lib /usr/lib64 -- libs=-lbind -lnsl -ldbm -ldb -ldl -lld -lm -lcrypt -lc -- perllibs=-lbind -lnsl -ldl -lld -lm -lcrypt -lc -+ libs=-lbind -ldbm -ldb -ldl -lld -lm -lcrypt -lc -+ perllibs=-lbind -ldl -lld -lm -lcrypt -lc - libc=/lib/libc.a, so=a, useshrplib=false, libperl=libperl.a - gnulibc_version='' - Dynamic Linking: -diff --git a/cpan/Config-Perl-V/t/25_plv516.t b/cpan/Config-Perl-V/t/25_plv516.t -index 5505245..5bad2ce 100644 ---- a/cpan/Config-Perl-V/t/25_plv516.t -+++ b/cpan/Config-Perl-V/t/25_plv516.t -@@ -69,8 +69,8 @@ Summary of my perl5 (revision 5 version 16 subversion 3) configuration: - Linker and Libraries: - ld='cc', ldflags ='-L/pro/local/lib -fstack-protector' - libpth=/pro/local/lib /lib /usr/lib /usr/local/lib -- libs=-lnsl -lgdbm -ldb -ldl -lm -lcrypt -lutil -lc -lgdbm_compat -- perllibs=-lnsl -ldl -lm -lcrypt -lutil -lc -+ libs=-lgdbm -ldb -ldl -lm -lcrypt -lutil -lc -lgdbm_compat -+ perllibs=-ldl -lm -lcrypt -lutil -lc - libc=/lib/libc-2.15.so, so=so, useshrplib=false, libperl=libperl.a - gnulibc_version='2.15' - Dynamic Linking: -diff --git a/cpan/Config-Perl-V/t/26_plv518.t b/cpan/Config-Perl-V/t/26_plv518.t -index a255797..d3ab0b6 100644 ---- a/cpan/Config-Perl-V/t/26_plv518.t -+++ b/cpan/Config-Perl-V/t/26_plv518.t -@@ -94,8 +94,8 @@ Summary of my perl5 (revision 5 version 18 subversion 0) configuration: - Linker and Libraries: - ld='cc', ldflags ='-L/pro/local/lib -fstack-protector' - libpth=/pro/local/lib /lib /usr/lib /usr/local/lib -- libs=-lnsl -lgdbm -ldb -ldl -lm -lcrypt -lutil -lc -lgdbm_compat -- perllibs=-lnsl -ldl -lm -lcrypt -lutil -lc -+ libs=-lgdbm -ldb -ldl -lm -lcrypt -lutil -lc -lgdbm_compat -+ perllibs=-ldl -lm -lcrypt -lutil -lc - libc=/lib/libc-2.17.so, so=so, useshrplib=false, libperl=libperl.a - gnulibc_version='2.17' - Dynamic Linking: -diff --git a/cpan/Config-Perl-V/t/26_plv5182.t b/cpan/Config-Perl-V/t/26_plv5182.t -index 25e52bb..fc24cd1 100644 ---- a/cpan/Config-Perl-V/t/26_plv5182.t -+++ b/cpan/Config-Perl-V/t/26_plv5182.t -@@ -94,8 +94,8 @@ Summary of my perl5 (revision 5 version 18 subversion 2) configuration: - Linker and Libraries: - ld='cc', ldflags ='-L/pro/local/lib -fstack-protector' - libpth=/pro/local/lib /lib /usr/lib /usr/local/lib -- libs=-lnsl -lgdbm -ldb -ldl -lm -lcrypt -lutil -lc -lgdbm_compat -- perllibs=-lnsl -ldl -lm -lcrypt -lutil -lc -+ libs=-lgdbm -ldb -ldl -lm -lcrypt -lutil -lc -lgdbm_compat -+ perllibs=-ldl -lm -lcrypt -lutil -lc - libc=/lib/libc-2.18.so, so=so, useshrplib=false, libperl=libperl.a - gnulibc_version='2.18' - Dynamic Linking: -diff --git a/cpan/Config-Perl-V/t/27_plv5200.t b/cpan/Config-Perl-V/t/27_plv5200.t -index f44273d..ca84b18 100644 ---- a/cpan/Config-Perl-V/t/27_plv5200.t -+++ b/cpan/Config-Perl-V/t/27_plv5200.t -@@ -96,8 +96,8 @@ Summary of my perl5 (revision 5 version 20 subversion 0) configuration: - Linker and Libraries: - ld='cc', ldflags ='-L/pro/local/lib -fstack-protector' - libpth=/usr/local/lib /usr/lib/gcc/i586-suse-linux/4.8/include-fixed /usr/lib/gcc/i586-suse-linux/4.8/../../../../i586-suse-linux/lib /usr/lib /pro/local/lib /lib -- libs=-lnsl -lgdbm -ldb -ldl -lm -lcrypt -lutil -lpthread -lc -lgdbm_compat -- perllibs=-lnsl -ldl -lm -lcrypt -lutil -lpthread -lc -+ libs=-lgdbm -ldb -ldl -lm -lcrypt -lutil -lpthread -lc -lgdbm_compat -+ perllibs=-ldl -lm -lcrypt -lutil -lpthread -lc - libc=libc-2.18.so, so=so, useshrplib=false, libperl=libperl.a - gnulibc_version='2.18' - Dynamic Linking: -diff --git a/cpan/Config-Perl-V/t/27_plv5202.t b/cpan/Config-Perl-V/t/27_plv5202.t -index 83c3cb0..13b58a2 100644 ---- a/cpan/Config-Perl-V/t/27_plv5202.t -+++ b/cpan/Config-Perl-V/t/27_plv5202.t -@@ -97,8 +97,8 @@ Summary of my perl5 (revision 5 version 20 subversion 2) configuration: - Linker and Libraries: - ld='cc', ldflags ='-L/pro/local/lib -fstack-protector' - libpth=/usr/local/lib /usr/lib64/gcc/x86_64-suse-linux/4.8/include-fixed /usr/lib64/gcc/x86_64-suse-linux/4.8/../../../../x86_64-suse-linux/lib /usr/lib /pro/local/lib /lib/../lib64 /usr/lib/../lib64 /lib /lib64 /usr/lib64 /usr/local/lib64 -- libs=-lnsl -lgdbm -ldb -ldl -lm -lcrypt -lutil -lpthread -lc -lgdbm_compat -- perllibs=-lnsl -ldl -lm -lcrypt -lutil -lpthread -lc -+ libs=-lgdbm -ldb -ldl -lm -lcrypt -lutil -lpthread -lc -lgdbm_compat -+ perllibs=-ldl -lm -lcrypt -lutil -lpthread -lc - libc=libc-2.19.so, so=so, useshrplib=false, libperl=libperl.a - gnulibc_version='2.19' - Dynamic Linking: -diff --git a/cpan/Config-Perl-V/t/28_plv5220.t b/cpan/Config-Perl-V/t/28_plv5220.t -index 885445b..26506c3 100644 ---- a/cpan/Config-Perl-V/t/28_plv5220.t -+++ b/cpan/Config-Perl-V/t/28_plv5220.t -@@ -97,8 +97,8 @@ Summary of my perl5 (revision 5 version 22 subversion 0) configuration: - Linker and Libraries: - ld='cc', ldflags ='-L/pro/local/lib -fstack-protector' - libpth=/usr/local/lib /usr/lib64/gcc/x86_64-suse-linux/4.8/include-fixed /usr/lib64/gcc/x86_64-suse-linux/4.8/../../../../x86_64-suse-linux/lib /usr/lib /pro/local/lib /lib/../lib64 /usr/lib/../lib64 /lib /lib64 /usr/lib64 /usr/local/lib64 -- libs=-lpthread -lnsl -lgdbm -ldb -ldl -lm -lcrypt -lutil -lc -lgdbm_compat -- perllibs=-lpthread -lnsl -ldl -lm -lcrypt -lutil -lc -+ libs=-lpthread -lgdbm -ldb -ldl -lm -lcrypt -lutil -lc -lgdbm_compat -+ perllibs=-lpthread -ldl -lm -lcrypt -lutil -lc - libc=libc-2.19.so, so=so, useshrplib=false, libperl=libperl.a - gnulibc_version='2.19' - Dynamic Linking: -diff --git a/cpan/Config-Perl-V/t/30_plv5240.t b/cpan/Config-Perl-V/t/30_plv5240.t -index 2d6c0fd..c4a8e13 100644 ---- a/cpan/Config-Perl-V/t/30_plv5240.t -+++ b/cpan/Config-Perl-V/t/30_plv5240.t -@@ -102,8 +102,8 @@ Summary of my perl5 (revision 5 version 24 subversion 0) configuration: - Linker and Libraries: - ld='cc', ldflags ='-L/pro/local/lib -fstack-protector-strong' - libpth=/usr/local/lib /usr/lib64/gcc/x86_64-suse-linux/5/include-fixed /usr/lib64/gcc/x86_64-suse-linux/5/../../../../x86_64-suse-linux/lib /usr/lib /pro/local/lib /lib/../lib64 /usr/lib/../lib64 /lib /lib64 /usr/lib64 /usr/local/lib64 -- libs=-lpthread -lnsl -lgdbm -ldb -ldl -lm -lcrypt -lutil -lc -lgdbm_compat -- perllibs=-lpthread -lnsl -ldl -lm -lcrypt -lutil -lc -+ libs=-lpthread -lgdbm -ldb -ldl -lm -lcrypt -lutil -lc -lgdbm_compat -+ perllibs=-lpthread -ldl -lm -lcrypt -lutil -lc - libc=libc-2.23.so, so=so, useshrplib=false, libperl=libperl.a - gnulibc_version='2.23' - Dynamic Linking: -diff --git a/cpan/Config-Perl-V/t/31_plv52511.t b/cpan/Config-Perl-V/t/31_plv52511.t -index a5b39ca..bcceca7 100644 ---- a/cpan/Config-Perl-V/t/31_plv52511.t -+++ b/cpan/Config-Perl-V/t/31_plv52511.t -@@ -131,8 +131,8 @@ Summary of my perl5 (revision 5 version 25 subversion 11) configuration: - ld='cc' - ldflags ='-L/pro/local/lib -fstack-protector-strong' - libpth=/usr/local/lib /usr/lib64/gcc/x86_64-suse-linux/6/include-fixed /usr/lib64/gcc/x86_64-suse-linux/6/../../../../x86_64-suse-linux/lib /usr/lib /pro/local/lib /lib/../lib64 /usr/lib/../lib64 /lib /lib64 /usr/lib64 /usr/local/lib64 -- libs=-lpthread -lnsl -lgdbm -ldb -ldl -lm -lcrypt -lutil -lc -lgdbm_compat -- perllibs=-lpthread -lnsl -ldl -lm -lcrypt -lutil -lc -+ libs=-lpthread -lgdbm -ldb -ldl -lm -lcrypt -lutil -lc -lgdbm_compat -+ perllibs=-lpthread -ldl -lm -lcrypt -lutil -lc - libc=libc-2.24.so - so=so - useshrplib=false -diff --git a/cpan/Config-Perl-V/t/32_plv5261rc1.t b/cpan/Config-Perl-V/t/32_plv5261rc1.t -index 9db16b2..57b1e11 100644 ---- a/cpan/Config-Perl-V/t/32_plv5261rc1.t -+++ b/cpan/Config-Perl-V/t/32_plv5261rc1.t -@@ -130,8 +130,8 @@ Summary of my perl5 (revision 5 version 26 subversion 1) configuration: - ld='ccache cc' - ldflags ='-L/pro/local/lib -fstack-protector' - libpth=/usr/local/lib /usr/lib64/gcc/x86_64-suse-linux/4.8/include-fixed /usr/lib64/gcc/x86_64-suse-linux/4.8/../../../../x86_64-suse-linux/lib /usr/lib /pro/local/lib /lib/../lib64 /usr/lib/../lib64 /lib /lib64 /usr/lib64 /usr/local/lib64 -- libs=-lpthread -lnsl -ldb -ldl -lm -lcrypt -lutil -lc -- perllibs=-lpthread -lnsl -ldl -lm -lcrypt -lutil -lc -+ libs=-lpthread -ldb -ldl -lm -lcrypt -lutil -lc -+ perllibs=-lpthread -ldl -lm -lcrypt -lutil -lc - libc=libc-2.19.so - so=so - useshrplib=false -diff --git a/cpan/Config-Perl-V/t/33_plv52711r.t b/cpan/Config-Perl-V/t/33_plv52711r.t -index c6940d2..d7f2147 100644 ---- a/cpan/Config-Perl-V/t/33_plv52711r.t -+++ b/cpan/Config-Perl-V/t/33_plv52711r.t -@@ -130,8 +130,8 @@ Summary of my perl5 (revision 5 version 27 subversion 11) configuration: - ld='cc' - ldflags ='-L/pro/local/lib -fstack-protector-strong' - libpth=/usr/local/lib /usr/lib64/gcc/x86_64-suse-linux/7/include-fixed /usr/lib64/gcc/x86_64-suse-linux/7/../../../../x86_64-suse-linux/lib /usr/lib /pro/local/lib /lib/../lib64 /usr/lib/../lib64 /lib /lib64 /usr/lib64 /usr/local/lib64 -- libs=-lpthread -lnsl -lgdbm -ldb -ldl -lm -lcrypt -lutil -lc -lgdbm_compat -- perllibs=-lpthread -lnsl -ldl -lm -lcrypt -lutil -lc -+ libs=-lpthread -lgdbm -ldb -ldl -lm -lcrypt -lutil -lc -lgdbm_compat -+ perllibs=-lpthread -ldl -lm -lcrypt -lutil -lc - libc=libc-2.27.so - so=so - useshrplib=false -diff --git a/cpan/Config-Perl-V/t/34_plv5280.t b/cpan/Config-Perl-V/t/34_plv5280.t -index f6c38df..47a1e0e 100644 ---- a/cpan/Config-Perl-V/t/34_plv5280.t -+++ b/cpan/Config-Perl-V/t/34_plv5280.t -@@ -129,8 +129,8 @@ Summary of my perl5 (revision 5 version 28 subversion 0) configuration: - ld='cc' - ldflags ='-L/pro/local/lib -fstack-protector-strong' - libpth=/usr/local/lib /usr/lib64/gcc/x86_64-suse-linux/8/include-fixed /usr/lib64/gcc/x86_64-suse-linux/8/../../../../x86_64-suse-linux/lib /usr/lib /pro/local/lib /lib/../lib64 /usr/lib/../lib64 /lib /lib64 /usr/lib64 /usr/local/lib64 -- libs=-lpthread -lnsl -lgdbm -ldb -ldl -lm -lcrypt -lutil -lc -lgdbm_compat -- perllibs=-lpthread -lnsl -ldl -lm -lcrypt -lutil -lc -+ libs=-lpthread -lgdbm -ldb -ldl -lm -lcrypt -lutil -lc -lgdbm_compat -+ perllibs=-lpthread -ldl -lm -lcrypt -lutil -lc - libc=libc-2.27.so - so=so - useshrplib=false -diff --git a/plan9/config_sh.sample b/plan9/config_sh.sample -index cd494c4..cf0d41b 100644 ---- a/plan9/config_sh.sample -+++ b/plan9/config_sh.sample -@@ -856,7 +856,7 @@ libsdirs='' - libsfiles='' - libsfound='' - libspath=' /lib' --libswanted='socket bind inet nsl nm ndbm gdbm dbm db malloc dl ld sun m c cposix posix ndir dir crypt sec ucb bsd BSD PW x util' -+libswanted='socket bind inet nm ndbm gdbm dbm db malloc dl ld sun m c cposix posix ndir dir crypt sec ucb bsd BSD PW x util' - libswanted_uselargefiles='' - line='' - lint='' -diff --git a/pod/perlrun.pod b/pod/perlrun.pod -index 89a7aa8..f92a2a5 100644 ---- a/pod/perlrun.pod -+++ b/pod/perlrun.pod -@@ -895,11 +895,11 @@ non-letters). For example: - $ perl -V:libc - libc='/lib/libc-2.2.4.so'; - $ perl -V:lib. -- libs='-lnsl -lgdbm -ldb -ldl -lm -lcrypt -lutil -lc'; -+ libs='-lgdbm -ldb -ldl -lm -lcrypt -lutil -lc'; - libc='/lib/libc-2.2.4.so'; - $ perl -V:lib.* - libpth='/usr/local/lib /lib /usr/lib'; -- libs='-lnsl -lgdbm -ldb -ldl -lm -lcrypt -lutil -lc'; -+ libs='-lgdbm -ldb -ldl -lm -lcrypt -lutil -lc'; - lib_ext='.a'; - libc='/lib/libc-2.2.4.so'; - libperl='libperl.a'; -diff --git a/win32/config.gc b/win32/config.gc -index 793b455..bb6ea3f 100644 ---- a/win32/config.gc -+++ b/win32/config.gc -@@ -868,8 +868,8 @@ libsdirs='' - libsfiles='' - libsfound='' - libspath='' --libswanted='net socket inet nsl nm ndbm gdbm dbm db malloc dl ld sun m c cposix posix ndir dir crypt ucb bsd BSD PW x' --libswanted_uselargefiles='net socket inet nsl nm ndbm gdbm dbm db malloc dl ld sun m c cposix posix ndir dir crypt ucb bsd BSD PW x' -+libswanted='net socket inet nm ndbm gdbm dbm db malloc dl ld sun m c cposix posix ndir dir crypt ucb bsd BSD PW x' -+libswanted_uselargefiles='net socket inet nm ndbm gdbm dbm db malloc dl ld sun m c cposix posix ndir dir crypt ucb bsd BSD PW x' - line='line' - lint='' - lkflags='' -diff --git a/win32/config.vc b/win32/config.vc -index a2c3f5a..f223095 100644 ---- a/win32/config.vc -+++ b/win32/config.vc -@@ -867,8 +867,8 @@ libsdirs='' - libsfiles='' - libsfound='' - libspath='' --libswanted='net socket inet nsl nm ndbm gdbm dbm db malloc dl ld sun m c cposix posix ndir dir crypt ucb bsd BSD PW x' --libswanted_uselargefiles='net socket inet nsl nm ndbm gdbm dbm db malloc dl ld sun m c cposix posix ndir dir crypt ucb bsd BSD PW x' -+libswanted='net socket inet nm ndbm gdbm dbm db malloc dl ld sun m c cposix posix ndir dir crypt ucb bsd BSD PW x' -+libswanted_uselargefiles='net socket inet nm ndbm gdbm dbm db malloc dl ld sun m c cposix posix ndir dir crypt ucb bsd BSD PW x' - line='line' - lint='' - lkflags='' diff --git a/omnibus/config/patches/perl/perl-5.34.0-remove_lnsl.patch b/omnibus/config/patches/perl/perl-5.34.0-remove_lnsl.patch deleted file mode 100644 index c8e2e81c3..000000000 --- a/omnibus/config/patches/perl/perl-5.34.0-remove_lnsl.patch +++ /dev/null @@ -1,516 +0,0 @@ -diff --git a/Configure b/Configure -index 913e080..a015175 100755 ---- a/Configure -+++ b/Configure -@@ -1493,7 +1493,7 @@ archname='' - usereentrant='undef' - : List of libraries we want. - : If anyone needs extra -lxxx, put those in a hint file. --libswanted="cl pthread socket bind inet nsl ndbm gdbm dbm db malloc dl ld" -+libswanted="cl pthread socket bind inet ndbm gdbm dbm db malloc dl ld" - libswanted="$libswanted sun m crypt sec util c cposix posix ucb bsd BSD" - : We probably want to search /usr/shlib before most other libraries. - : This is only used by the lib/ExtUtils/MakeMaker.pm routine extliblist. -diff --git a/Cross/config.sh-arm-linux b/Cross/config.sh-arm-linux -index 33bab37..910e834 100644 ---- a/Cross/config.sh-arm-linux -+++ b/Cross/config.sh-arm-linux -@@ -870,12 +870,12 @@ lib_ext='.a' - libc='/lib/libc-2.2.2.so' - libperl='libperl.so' - libpth='/usr/local/lib /lib /usr/lib' --libs='-lnsl -ldl -lm -lcrypt -lutil -lc' -+libs='-ldl -lm -lcrypt -lutil -lc' - libsdirs=' /usr/lib' --libsfiles=' libnsl.so libdl.so libm.so libcrypt.so libutil.so libc.so' --libsfound=' /usr/lib/libnsl.so /usr/lib/libdl.so /usr/lib/libm.so /usr/lib/libcrypt.so /usr/lib/libutil.so /usr/lib/libc.so' -+libsfiles=' libdl.so libm.so libcrypt.so libutil.so libc.so' -+libsfound=' /usr/lib/libdl.so /usr/lib/libm.so /usr/lib/libcrypt.so /usr/lib/libutil.so /usr/lib/libc.so' - libspath=' /usr/local/lib /lib /usr/lib' --libswanted='socket bind inet nsl nm ndbm gdbm dbm db malloc dl ld sun m crypt sec util c cposix posix ucb BSD' -+libswanted='socket bind inet nm ndbm gdbm dbm db malloc dl ld sun m crypt sec util c cposix posix ucb BSD' - libswanted_uselargefiles='' - line='' - lint='' -@@ -963,7 +963,7 @@ perl='' - perl_patchlevel='' - perl_static_inline='static' - perladmin='red@criticalintegration.com' --perllibs='-lnsl -ldl -lm -lcrypt -lutil -lc' -+perllibs='-ldl -lm -lcrypt -lutil -lc' - perlpath='/usr/bin/perl' - pg='pg' - phostname='hostname' -diff --git a/Cross/config.sh-arm-linux-n770 b/Cross/config.sh-arm-linux-n770 -index 73567fb..08288ce 100644 ---- a/Cross/config.sh-arm-linux-n770 -+++ b/Cross/config.sh-arm-linux-n770 -@@ -868,12 +868,12 @@ lib_ext='.arma' - libc='/lib/libc-2.2.2.so' - libperl='libperl.arma' - libpth='/usr/local/lib /lib /usr/lib' --libs='-lnsl -ldl -lm -lcrypt -lutil -lc' -+libs='-ldl -lm -lcrypt -lutil -lc' - libsdirs=' /usr/lib' --libsfiles=' libnsl.so libdl.so libm.so libcrypt.so libutil.so libc.so' --libsfound=' /usr/lib/libnsl.so /usr/lib/libdl.so /usr/lib/libm.so /usr/lib/libcrypt.so /usr/lib/libutil.so /usr/lib/libc.so' -+libsfiles=' libdl.so libm.so libcrypt.so libutil.so libc.so' -+libsfound=' /usr/lib/libdl.so /usr/lib/libm.so /usr/lib/libcrypt.so /usr/lib/libutil.so /usr/lib/libc.so' - libspath=' /usr/local/lib /lib /usr/lib' --libswanted='socket bind inet nsl nm ndbm gdbm dbm db malloc dl ld sun m crypt sec util c cposix posix ucb BSD' -+libswanted='socket bind inet nm ndbm gdbm dbm db malloc dl ld sun m crypt sec util c cposix posix ucb BSD' - libswanted_uselargefiles='' - line='' - lint='' -@@ -961,7 +961,7 @@ perl='' - perl_patchlevel='' - perl_static_inline='static' - perladmin='red@criticalintegration.com' --perllibs='-lnsl -ldl -lm -lcrypt -lutil -lc' -+perllibs='-ldl -lm -lcrypt -lutil -lc' - perlpath='/usr/bin/perl' - pg='pg' - phostname='hostname' -diff --git a/INSTALL b/INSTALL -index ce5ad45..da89b58 100644 ---- a/INSTALL -+++ b/INSTALL -@@ -1653,7 +1653,7 @@ If the build of miniperl fails with a long list of missing functions or - undefined symbols, check the libs variable in the config.sh file. It - should look something like - -- libs='-lsocket -lnsl -ldl -lm -lc' -+ libs='-lsocket -ldl -lm -lc' - - The exact libraries will vary from system to system, but you typically - need to include at least the math library -lm. Normally, Configure -diff --git a/NetWare/config.wc b/NetWare/config.wc -index 26c1755..5fd4985 100644 ---- a/NetWare/config.wc -+++ b/NetWare/config.wc -@@ -850,7 +850,7 @@ libsdirs='' - libsfiles='' - libsfound='' - libspath='' --libswanted='net socket inet nsl nm ndbm gdbm dbm db malloc dl ld sun m c cposix posix ndir dir crypt ucb bsd BSD PW x' -+libswanted='net socket inet nm ndbm gdbm dbm db malloc dl ld sun m c cposix posix ndir dir crypt ucb bsd BSD PW x' - line='line' - lint='' - lkflags='' -diff --git a/Porting/bisect-runner.pl b/Porting/bisect-runner.pl -index b6c75a9..33de0c0 100755 ---- a/Porting/bisect-runner.pl -+++ b/Porting/bisect-runner.pl -@@ -1550,7 +1550,7 @@ unless (extract_from_file('Configure', 'ignore_versioned_solibs')) { - my @libs; - # This is the current libswanted list from Configure, less the libs removed - # by current hints/linux.sh -- foreach my $lib (qw(sfio socket inet nsl nm ndbm gdbm dbm db malloc dl -+ foreach my $lib (qw(sfio socket inet nm ndbm gdbm dbm db malloc dl - ld sun m crypt sec util c cposix posix ucb BSD)) { - foreach my $dir (@paths) { - # Note the wonderful consistency of dot-or-not in the config vars: -diff --git a/Porting/config.sh b/Porting/config.sh -index d1f54f2..f126291 100644 ---- a/Porting/config.sh -+++ b/Porting/config.sh -@@ -900,12 +900,12 @@ lib_ext='.a' - libc='libc-2.31.so' - libperl='libperl.a' - libpth='/usr/local/lib /usr/lib64/gcc/x86_64-suse-linux/10/include-fixed /usr/lib64/gcc/x86_64-suse-linux/10/../../../../x86_64-suse-linux/lib /usr/lib /lib/../lib64 /usr/lib/../lib64 /lib /lib64 /usr/lib64 /usr/local/lib64' --libs='-lpthread -lnsl -lgdbm -ldb -ldl -lm -lcrypt -lutil -lc -lgdbm_compat' -+libs='-lpthread -lgdbm -ldb -ldl -lm -lcrypt -lutil -lc -lgdbm_compat' - libsdirs=' /usr/lib/../lib64' --libsfiles=' libpthread.so libnsl.so libgdbm.so libdb.so libdl.so libm.so libcrypt.so libutil.so libc.so libgdbm_compat.so' --libsfound=' /usr/lib/../lib64/libpthread.so /usr/lib/../lib64/libnsl.so /usr/lib/../lib64/libgdbm.so /usr/lib/../lib64/libdb.so /usr/lib/../lib64/libdl.so /usr/lib/../lib64/libm.so /usr/lib/../lib64/libcrypt.so /usr/lib/../lib64/libutil.so /usr/lib/../lib64/libc.so /usr/lib/../lib64/libgdbm_compat.so' -+libsfiles=' libpthread.so libgdbm.so libdb.so libdl.so libm.so libcrypt.so libutil.so libc.so libgdbm_compat.so' -+libsfound=' /usr/lib/../lib64/libpthread.so /usr/lib/../lib64/libgdbm.so /usr/lib/../lib64/libdb.so /usr/lib/../lib64/libdl.so /usr/lib/../lib64/libm.so /usr/lib/../lib64/libcrypt.so /usr/lib/../lib64/libutil.so /usr/lib/../lib64/libc.so /usr/lib/../lib64/libgdbm_compat.so' - libspath=' /usr/local/lib /usr/lib64/gcc/x86_64-suse-linux/10/include-fixed /usr/lib64/gcc/x86_64-suse-linux/10/../../../../x86_64-suse-linux/lib /usr/lib /lib/../lib64 /usr/lib/../lib64 /lib /lib64 /usr/lib64 /usr/local/lib64' --libswanted='cl pthread cl pthread socket inet nsl gdbm dbm db malloc dl ld sun m crypt sec util c cposix posix ucb BSD gdbm_compat' -+libswanted='cl pthread cl pthread socket inet gdbm dbm db malloc dl ld sun m crypt sec util c cposix posix ucb BSD gdbm_compat' - libswanted_uselargefiles='' - line='' - lint='' -@@ -992,7 +992,7 @@ perl='perl' - perl_patchlevel='' - perl_static_inline='static __inline__' - perladmin='yourname@yourhost.yourplace.com' --perllibs='-lpthread -lnsl -ldl -lm -lcrypt -lutil -lc' -+perllibs='-lpthread -ldl -lm -lcrypt -lutil -lc' - perlpath='/opt/perl/bin/perl5.34.0' - pg='pg' - phostname='' -diff --git a/configure.com b/configure.com -index df29582..0171264 100644 ---- a/configure.com -+++ b/configure.com -@@ -117,7 +117,7 @@ $!: is prepended to libpth. This variable takes care of special !sfn - $!: machines, like the mips. Usually, it should be empty. !sfn - $!plibpth='' !sfn - $!: List of libraries we want. !sfn --$!libswanted='net socket inet nsl nm ndbm gdbm dbm db malloc dl' !sfn -+$!libswanted='net socket inet nm ndbm gdbm dbm db malloc dl' !sfn - $!libswanted="$libswanted ld sun m c cposix posix ndir dir crypt" !sfn - $!libswanted="$libswanted ucb bsd BSD PW x" !sfn - $!: We probably want to search /usr/shlib before most other libraries. !sfn -diff --git a/cpan/Config-Perl-V/t/20_plv56.t b/cpan/Config-Perl-V/t/20_plv56.t -index 252a162..5004c9a 100644 ---- a/cpan/Config-Perl-V/t/20_plv56.t -+++ b/cpan/Config-Perl-V/t/20_plv56.t -@@ -63,8 +63,8 @@ Summary of my perl5 (revision 5.0 version 6 subversion 2) configuration: - Linker and Libraries: - ld='cc', ldflags ='-L/pro/local/lib' - libpth=/pro/local/lib /lib /usr/lib /usr/local/lib -- libs=-lnsl -lgdbm -ldb -ldl -lm -lc -lcrypt -lutil -- perllibs=-lnsl -ldl -lm -lc -lcrypt -lutil -+ libs=-lgdbm -ldb -ldl -lm -lc -lcrypt -lutil -+ perllibs=-ldl -lm -lc -lcrypt -lutil - libc=/lib/libc-2.10.1.so, so=so, useshrplib=false, libperl=libperl.a - Dynamic Linking: - dlsrc=dl_dlopen.xs, dlext=so, d_dlsymun=undef, ccdlflags='-rdynamic' -diff --git a/cpan/Config-Perl-V/t/21_plv58.t b/cpan/Config-Perl-V/t/21_plv58.t -index b354e24..d747355 100644 ---- a/cpan/Config-Perl-V/t/21_plv58.t -+++ b/cpan/Config-Perl-V/t/21_plv58.t -@@ -67,8 +67,8 @@ Summary of my perl5 (revision 5 version 8 subversion 9) configuration: - Linker and Libraries: - ld='cc', ldflags ='-L/pro/local/lib' - libpth=/pro/local/lib /lib /usr/lib /usr/local/lib -- libs=-lnsl -lgdbm -ldb -ldl -lm -lcrypt -lutil -lpthread -lc -- perllibs=-lnsl -ldl -lm -lcrypt -lutil -lpthread -lc -+ libs=-lgdbm -ldb -ldl -lm -lcrypt -lutil -lpthread -lc -+ perllibs=-ldl -lm -lcrypt -lutil -lpthread -lc - libc=/lib/libc-2.11.2.so, so=so, useshrplib=false, libperl=libperl.a - gnulibc_version='2.11.2' - Dynamic Linking: -diff --git a/cpan/Config-Perl-V/t/22_plv510.t b/cpan/Config-Perl-V/t/22_plv510.t -index bec688c..4641d12 100644 ---- a/cpan/Config-Perl-V/t/22_plv510.t -+++ b/cpan/Config-Perl-V/t/22_plv510.t -@@ -57,8 +57,8 @@ Summary of my perl5 (revision 5 version 10 subversion 0) configuration: - Linker and Libraries: - ld='cc', ldflags ='-L/pro/local/lib' - libpth=/pro/local/lib /lib /usr/lib /usr/local/lib -- libs=-lnsl -lgdbm -ldb -ldl -lm -lcrypt -lutil -lc -- perllibs=-lnsl -ldl -lm -lcrypt -lutil -lc -+ libs=-lgdbm -ldb -ldl -lm -lcrypt -lutil -lc -+ perllibs=-ldl -lm -lcrypt -lutil -lc - libc=/lib/libc-2.6.1.so, so=so, useshrplib=false, libperl=libperl.a - gnulibc_version='2.6.1' - Dynamic Linking: -diff --git a/cpan/Config-Perl-V/t/23_plv512.t b/cpan/Config-Perl-V/t/23_plv512.t -index 03c69cb..47d7f97 100644 ---- a/cpan/Config-Perl-V/t/23_plv512.t -+++ b/cpan/Config-Perl-V/t/23_plv512.t -@@ -68,8 +68,8 @@ Summary of my perl5 (revision 5 version 12 subversion 2) configuration: - Linker and Libraries: - ld='/usr/bin/ld', ldflags ='-L/pro/local/lib +DD64 -L/usr/lib/hpux64' - libpth=/pro/local/lib /usr/lib/hpux64 /lib /usr/lib /usr/ccs/lib /usr/local/lib -- libs=-lcl -lpthread -lnsl -lnm -ldb -ldl -ldld -lm -lsec -lc -- perllibs=-lcl -lpthread -lnsl -lnm -ldl -ldld -lm -lsec -lc -+ libs=-lcl -lpthread -lnm -ldb -ldl -ldld -lm -lsec -lc -+ perllibs=-lcl -lpthread -lnm -ldl -ldld -lm -lsec -lc - libc=/usr/lib/hpux64/libc.so, so=so, useshrplib=false, libperl=libperl.a - gnulibc_version='' - Dynamic Linking: -diff --git a/cpan/Config-Perl-V/t/24_plv514.t b/cpan/Config-Perl-V/t/24_plv514.t -index 3377b41..fdd8046 100644 ---- a/cpan/Config-Perl-V/t/24_plv514.t -+++ b/cpan/Config-Perl-V/t/24_plv514.t -@@ -69,8 +69,8 @@ Summary of my perl5 (revision 5 version 14 subversion 2) configuration: - Linker and Libraries: - ld='ld', ldflags ='-L/usr/local/ppc64/lib64 -b64 -q64 -L/pro/local/lib -brtl -bdynamic -b64' - libpth=/usr/local/ppc64/lib64 /lib /usr/lib /usr/ccs/lib /usr/local/lib /usr/lib64 -- libs=-lbind -lnsl -ldbm -ldb -ldl -lld -lm -lcrypt -lc -- perllibs=-lbind -lnsl -ldl -lld -lm -lcrypt -lc -+ libs=-lbind -ldbm -ldb -ldl -lld -lm -lcrypt -lc -+ perllibs=-lbind -ldl -lld -lm -lcrypt -lc - libc=/lib/libc.a, so=a, useshrplib=false, libperl=libperl.a - gnulibc_version='' - Dynamic Linking: -diff --git a/cpan/Config-Perl-V/t/25_plv516.t b/cpan/Config-Perl-V/t/25_plv516.t -index 5505245..5bad2ce 100644 ---- a/cpan/Config-Perl-V/t/25_plv516.t -+++ b/cpan/Config-Perl-V/t/25_plv516.t -@@ -69,8 +69,8 @@ Summary of my perl5 (revision 5 version 16 subversion 3) configuration: - Linker and Libraries: - ld='cc', ldflags ='-L/pro/local/lib -fstack-protector' - libpth=/pro/local/lib /lib /usr/lib /usr/local/lib -- libs=-lnsl -lgdbm -ldb -ldl -lm -lcrypt -lutil -lc -lgdbm_compat -- perllibs=-lnsl -ldl -lm -lcrypt -lutil -lc -+ libs=-lgdbm -ldb -ldl -lm -lcrypt -lutil -lc -lgdbm_compat -+ perllibs=-ldl -lm -lcrypt -lutil -lc - libc=/lib/libc-2.15.so, so=so, useshrplib=false, libperl=libperl.a - gnulibc_version='2.15' - Dynamic Linking: -diff --git a/cpan/Config-Perl-V/t/26_plv518.t b/cpan/Config-Perl-V/t/26_plv518.t -index a255797..d3ab0b6 100644 ---- a/cpan/Config-Perl-V/t/26_plv518.t -+++ b/cpan/Config-Perl-V/t/26_plv518.t -@@ -94,8 +94,8 @@ Summary of my perl5 (revision 5 version 18 subversion 0) configuration: - Linker and Libraries: - ld='cc', ldflags ='-L/pro/local/lib -fstack-protector' - libpth=/pro/local/lib /lib /usr/lib /usr/local/lib -- libs=-lnsl -lgdbm -ldb -ldl -lm -lcrypt -lutil -lc -lgdbm_compat -- perllibs=-lnsl -ldl -lm -lcrypt -lutil -lc -+ libs=-lgdbm -ldb -ldl -lm -lcrypt -lutil -lc -lgdbm_compat -+ perllibs=-ldl -lm -lcrypt -lutil -lc - libc=/lib/libc-2.17.so, so=so, useshrplib=false, libperl=libperl.a - gnulibc_version='2.17' - Dynamic Linking: -diff --git a/cpan/Config-Perl-V/t/26_plv5182.t b/cpan/Config-Perl-V/t/26_plv5182.t -index 25e52bb..fc24cd1 100644 ---- a/cpan/Config-Perl-V/t/26_plv5182.t -+++ b/cpan/Config-Perl-V/t/26_plv5182.t -@@ -94,8 +94,8 @@ Summary of my perl5 (revision 5 version 18 subversion 2) configuration: - Linker and Libraries: - ld='cc', ldflags ='-L/pro/local/lib -fstack-protector' - libpth=/pro/local/lib /lib /usr/lib /usr/local/lib -- libs=-lnsl -lgdbm -ldb -ldl -lm -lcrypt -lutil -lc -lgdbm_compat -- perllibs=-lnsl -ldl -lm -lcrypt -lutil -lc -+ libs=-lgdbm -ldb -ldl -lm -lcrypt -lutil -lc -lgdbm_compat -+ perllibs=-ldl -lm -lcrypt -lutil -lc - libc=/lib/libc-2.18.so, so=so, useshrplib=false, libperl=libperl.a - gnulibc_version='2.18' - Dynamic Linking: -diff --git a/cpan/Config-Perl-V/t/27_plv5200.t b/cpan/Config-Perl-V/t/27_plv5200.t -index f44273d..ca84b18 100644 ---- a/cpan/Config-Perl-V/t/27_plv5200.t -+++ b/cpan/Config-Perl-V/t/27_plv5200.t -@@ -96,8 +96,8 @@ Summary of my perl5 (revision 5 version 20 subversion 0) configuration: - Linker and Libraries: - ld='cc', ldflags ='-L/pro/local/lib -fstack-protector' - libpth=/usr/local/lib /usr/lib/gcc/i586-suse-linux/4.8/include-fixed /usr/lib/gcc/i586-suse-linux/4.8/../../../../i586-suse-linux/lib /usr/lib /pro/local/lib /lib -- libs=-lnsl -lgdbm -ldb -ldl -lm -lcrypt -lutil -lpthread -lc -lgdbm_compat -- perllibs=-lnsl -ldl -lm -lcrypt -lutil -lpthread -lc -+ libs=-lgdbm -ldb -ldl -lm -lcrypt -lutil -lpthread -lc -lgdbm_compat -+ perllibs=-ldl -lm -lcrypt -lutil -lpthread -lc - libc=libc-2.18.so, so=so, useshrplib=false, libperl=libperl.a - gnulibc_version='2.18' - Dynamic Linking: -diff --git a/cpan/Config-Perl-V/t/27_plv5202.t b/cpan/Config-Perl-V/t/27_plv5202.t -index 83c3cb0..13b58a2 100644 ---- a/cpan/Config-Perl-V/t/27_plv5202.t -+++ b/cpan/Config-Perl-V/t/27_plv5202.t -@@ -97,8 +97,8 @@ Summary of my perl5 (revision 5 version 20 subversion 2) configuration: - Linker and Libraries: - ld='cc', ldflags ='-L/pro/local/lib -fstack-protector' - libpth=/usr/local/lib /usr/lib64/gcc/x86_64-suse-linux/4.8/include-fixed /usr/lib64/gcc/x86_64-suse-linux/4.8/../../../../x86_64-suse-linux/lib /usr/lib /pro/local/lib /lib/../lib64 /usr/lib/../lib64 /lib /lib64 /usr/lib64 /usr/local/lib64 -- libs=-lnsl -lgdbm -ldb -ldl -lm -lcrypt -lutil -lpthread -lc -lgdbm_compat -- perllibs=-lnsl -ldl -lm -lcrypt -lutil -lpthread -lc -+ libs=-lgdbm -ldb -ldl -lm -lcrypt -lutil -lpthread -lc -lgdbm_compat -+ perllibs=-ldl -lm -lcrypt -lutil -lpthread -lc - libc=libc-2.19.so, so=so, useshrplib=false, libperl=libperl.a - gnulibc_version='2.19' - Dynamic Linking: -diff --git a/cpan/Config-Perl-V/t/28_plv5220.t b/cpan/Config-Perl-V/t/28_plv5220.t -index 885445b..26506c3 100644 ---- a/cpan/Config-Perl-V/t/28_plv5220.t -+++ b/cpan/Config-Perl-V/t/28_plv5220.t -@@ -97,8 +97,8 @@ Summary of my perl5 (revision 5 version 22 subversion 0) configuration: - Linker and Libraries: - ld='cc', ldflags ='-L/pro/local/lib -fstack-protector' - libpth=/usr/local/lib /usr/lib64/gcc/x86_64-suse-linux/4.8/include-fixed /usr/lib64/gcc/x86_64-suse-linux/4.8/../../../../x86_64-suse-linux/lib /usr/lib /pro/local/lib /lib/../lib64 /usr/lib/../lib64 /lib /lib64 /usr/lib64 /usr/local/lib64 -- libs=-lpthread -lnsl -lgdbm -ldb -ldl -lm -lcrypt -lutil -lc -lgdbm_compat -- perllibs=-lpthread -lnsl -ldl -lm -lcrypt -lutil -lc -+ libs=-lpthread -lgdbm -ldb -ldl -lm -lcrypt -lutil -lc -lgdbm_compat -+ perllibs=-lpthread -ldl -lm -lcrypt -lutil -lc - libc=libc-2.19.so, so=so, useshrplib=false, libperl=libperl.a - gnulibc_version='2.19' - Dynamic Linking: -diff --git a/cpan/Config-Perl-V/t/30_plv5240.t b/cpan/Config-Perl-V/t/30_plv5240.t -index 2d6c0fd..c4a8e13 100644 ---- a/cpan/Config-Perl-V/t/30_plv5240.t -+++ b/cpan/Config-Perl-V/t/30_plv5240.t -@@ -102,8 +102,8 @@ Summary of my perl5 (revision 5 version 24 subversion 0) configuration: - Linker and Libraries: - ld='cc', ldflags ='-L/pro/local/lib -fstack-protector-strong' - libpth=/usr/local/lib /usr/lib64/gcc/x86_64-suse-linux/5/include-fixed /usr/lib64/gcc/x86_64-suse-linux/5/../../../../x86_64-suse-linux/lib /usr/lib /pro/local/lib /lib/../lib64 /usr/lib/../lib64 /lib /lib64 /usr/lib64 /usr/local/lib64 -- libs=-lpthread -lnsl -lgdbm -ldb -ldl -lm -lcrypt -lutil -lc -lgdbm_compat -- perllibs=-lpthread -lnsl -ldl -lm -lcrypt -lutil -lc -+ libs=-lpthread -lgdbm -ldb -ldl -lm -lcrypt -lutil -lc -lgdbm_compat -+ perllibs=-lpthread -ldl -lm -lcrypt -lutil -lc - libc=libc-2.23.so, so=so, useshrplib=false, libperl=libperl.a - gnulibc_version='2.23' - Dynamic Linking: -diff --git a/cpan/Config-Perl-V/t/31_plv52511.t b/cpan/Config-Perl-V/t/31_plv52511.t -index a5b39ca..bcceca7 100644 ---- a/cpan/Config-Perl-V/t/31_plv52511.t -+++ b/cpan/Config-Perl-V/t/31_plv52511.t -@@ -131,8 +131,8 @@ Summary of my perl5 (revision 5 version 25 subversion 11) configuration: - ld='cc' - ldflags ='-L/pro/local/lib -fstack-protector-strong' - libpth=/usr/local/lib /usr/lib64/gcc/x86_64-suse-linux/6/include-fixed /usr/lib64/gcc/x86_64-suse-linux/6/../../../../x86_64-suse-linux/lib /usr/lib /pro/local/lib /lib/../lib64 /usr/lib/../lib64 /lib /lib64 /usr/lib64 /usr/local/lib64 -- libs=-lpthread -lnsl -lgdbm -ldb -ldl -lm -lcrypt -lutil -lc -lgdbm_compat -- perllibs=-lpthread -lnsl -ldl -lm -lcrypt -lutil -lc -+ libs=-lpthread -lgdbm -ldb -ldl -lm -lcrypt -lutil -lc -lgdbm_compat -+ perllibs=-lpthread -ldl -lm -lcrypt -lutil -lc - libc=libc-2.24.so - so=so - useshrplib=false -diff --git a/cpan/Config-Perl-V/t/32_plv5261rc1.t b/cpan/Config-Perl-V/t/32_plv5261rc1.t -index 9db16b2..57b1e11 100644 ---- a/cpan/Config-Perl-V/t/32_plv5261rc1.t -+++ b/cpan/Config-Perl-V/t/32_plv5261rc1.t -@@ -130,8 +130,8 @@ Summary of my perl5 (revision 5 version 26 subversion 1) configuration: - ld='ccache cc' - ldflags ='-L/pro/local/lib -fstack-protector' - libpth=/usr/local/lib /usr/lib64/gcc/x86_64-suse-linux/4.8/include-fixed /usr/lib64/gcc/x86_64-suse-linux/4.8/../../../../x86_64-suse-linux/lib /usr/lib /pro/local/lib /lib/../lib64 /usr/lib/../lib64 /lib /lib64 /usr/lib64 /usr/local/lib64 -- libs=-lpthread -lnsl -ldb -ldl -lm -lcrypt -lutil -lc -- perllibs=-lpthread -lnsl -ldl -lm -lcrypt -lutil -lc -+ libs=-lpthread -ldb -ldl -lm -lcrypt -lutil -lc -+ perllibs=-lpthread -ldl -lm -lcrypt -lutil -lc - libc=libc-2.19.so - so=so - useshrplib=false -diff --git a/cpan/Config-Perl-V/t/33_plv52711r.t b/cpan/Config-Perl-V/t/33_plv52711r.t -index c6940d2..d7f2147 100644 ---- a/cpan/Config-Perl-V/t/33_plv52711r.t -+++ b/cpan/Config-Perl-V/t/33_plv52711r.t -@@ -130,8 +130,8 @@ Summary of my perl5 (revision 5 version 27 subversion 11) configuration: - ld='cc' - ldflags ='-L/pro/local/lib -fstack-protector-strong' - libpth=/usr/local/lib /usr/lib64/gcc/x86_64-suse-linux/7/include-fixed /usr/lib64/gcc/x86_64-suse-linux/7/../../../../x86_64-suse-linux/lib /usr/lib /pro/local/lib /lib/../lib64 /usr/lib/../lib64 /lib /lib64 /usr/lib64 /usr/local/lib64 -- libs=-lpthread -lnsl -lgdbm -ldb -ldl -lm -lcrypt -lutil -lc -lgdbm_compat -- perllibs=-lpthread -lnsl -ldl -lm -lcrypt -lutil -lc -+ libs=-lpthread -lgdbm -ldb -ldl -lm -lcrypt -lutil -lc -lgdbm_compat -+ perllibs=-lpthread -ldl -lm -lcrypt -lutil -lc - libc=libc-2.27.so - so=so - useshrplib=false -diff --git a/cpan/Config-Perl-V/t/34_plv5280.t b/cpan/Config-Perl-V/t/34_plv5280.t -index f6c38df..47a1e0e 100644 ---- a/cpan/Config-Perl-V/t/34_plv5280.t -+++ b/cpan/Config-Perl-V/t/34_plv5280.t -@@ -129,8 +129,8 @@ Summary of my perl5 (revision 5 version 28 subversion 0) configuration: - ld='cc' - ldflags ='-L/pro/local/lib -fstack-protector-strong' - libpth=/usr/local/lib /usr/lib64/gcc/x86_64-suse-linux/8/include-fixed /usr/lib64/gcc/x86_64-suse-linux/8/../../../../x86_64-suse-linux/lib /usr/lib /pro/local/lib /lib/../lib64 /usr/lib/../lib64 /lib /lib64 /usr/lib64 /usr/local/lib64 -- libs=-lpthread -lnsl -lgdbm -ldb -ldl -lm -lcrypt -lutil -lc -lgdbm_compat -- perllibs=-lpthread -lnsl -ldl -lm -lcrypt -lutil -lc -+ libs=-lpthread -lgdbm -ldb -ldl -lm -lcrypt -lutil -lc -lgdbm_compat -+ perllibs=-lpthread -ldl -lm -lcrypt -lutil -lc - libc=libc-2.27.so - so=so - useshrplib=false -diff --git a/cpan/Config-Perl-V/t/35_plv52910g.t b/cpan/Config-Perl-V/t/35_plv52910g.t -index 6d822d1..383d146 100644 ---- a/cpan/Config-Perl-V/t/35_plv52910g.t -+++ b/cpan/Config-Perl-V/t/35_plv52910g.t -@@ -130,8 +130,8 @@ Summary of my perl5 (revision 5 version 29 subversion 10) configuration: - ld='g++' - ldflags ='-L/pro/local/lib -fstack-protector-strong' - libpth=/usr/include/c++/8 /usr/include/c++/8/x86_64-suse-linux /usr/include/c++/8/backward /usr/local/lib /usr/lib64/gcc/x86_64-suse-linux/8/include-fixed /usr/lib64/gcc/x86_64-suse-linux/8/../../../../x86_64-suse-linux/lib /usr/lib /pro/local/lib /lib/../lib64 /usr/lib/../lib64 /lib /lib64 /usr/lib64 /usr/local/lib64 -- libs=-lpthread -lnsl -lgdbm -ldb -ldl -lm -lcrypt -lutil -lc -lgdbm_compat -- perllibs=-lpthread -lnsl -ldl -lm -lcrypt -lutil -lc -+ libs=-lpthread -lgdbm -ldb -ldl -lm -lcrypt -lutil -lc -lgdbm_compat -+ perllibs=-lpthread -ldl -lm -lcrypt -lutil -lc - libc=libc-2.29.so - so=so - useshrplib=false -diff --git a/cpan/Config-Perl-V/t/36_plv5300.t b/cpan/Config-Perl-V/t/36_plv5300.t -index 6db7512..b3e26e3 100644 ---- a/cpan/Config-Perl-V/t/36_plv5300.t -+++ b/cpan/Config-Perl-V/t/36_plv5300.t -@@ -130,8 +130,8 @@ Summary of my perl5 (revision 5 version 30 subversion 0) configuration: - ld='cc' - ldflags ='-L/pro/local/lib -fstack-protector-strong' - libpth=/usr/local/lib /usr/lib64/gcc/x86_64-suse-linux/8/include-fixed /usr/lib64/gcc/x86_64-suse-linux/8/../../../../x86_64-suse-linux/lib /usr/lib /pro/local/lib /lib/../lib64 /usr/lib/../lib64 /lib /lib64 /usr/lib64 /usr/local/lib64 -- libs=-lpthread -lnsl -lgdbm -ldb -ldl -lm -lcrypt -lutil -lc -lgdbm_compat -- perllibs=-lpthread -lnsl -ldl -lm -lcrypt -lutil -lc -+ libs=-lpthread -lgdbm -ldb -ldl -lm -lcrypt -lutil -lc -lgdbm_compat -+ perllibs=-lpthread -ldl -lm -lcrypt -lutil -lc - libc=libc-2.29.so - so=so - useshrplib=true -diff --git a/cpan/Config-Perl-V/t/37_plv53111qm.t b/cpan/Config-Perl-V/t/37_plv53111qm.t -index f566f76..f94c275 100644 ---- a/cpan/Config-Perl-V/t/37_plv53111qm.t -+++ b/cpan/Config-Perl-V/t/37_plv53111qm.t -@@ -130,8 +130,8 @@ Summary of my perl5 (revision 5 version 31 subversion 11) configuration: - ld='cc' - ldflags ='-L/pro/local/lib -fstack-protector-strong' - libpth=/usr/local/lib /usr/lib64/gcc/x86_64-suse-linux/10/include-fixed /usr/lib64/gcc/x86_64-suse-linux/10/../../../../x86_64-suse-linux/lib /usr/lib /pro/local/lib /lib/../lib64 /usr/lib/../lib64 /lib /lib64 /usr/lib64 /usr/local/lib64 -- libs=-lpthread -lnsl -lgdbm -ldb -ldl -lm -lcrypt -lutil -lc -lgdbm_compat -lquadmath -- perllibs=-lpthread -lnsl -ldl -lm -lcrypt -lutil -lc -lquadmath -+ libs=-lpthread -lgdbm -ldb -ldl -lm -lcrypt -lutil -lc -lgdbm_compat -lquadmath -+ perllibs=-lpthread -ldl -lm -lcrypt -lutil -lc -lquadmath - libc=libc-2.31.so - so=so - useshrplib=false -diff --git a/cpan/Config-Perl-V/t/38_plv5320tld.t b/cpan/Config-Perl-V/t/38_plv5320tld.t -index a8f0d73..b1ba340 100644 ---- a/cpan/Config-Perl-V/t/38_plv5320tld.t -+++ b/cpan/Config-Perl-V/t/38_plv5320tld.t -@@ -130,8 +130,8 @@ Summary of my perl5 (revision 5 version 32 subversion 0) configuration: - ld='cc' - ldflags ='-L/pro/local/lib -fstack-protector-strong' - libpth=/usr/local/lib /usr/lib64/gcc/x86_64-suse-linux/10/include-fixed /usr/lib64/gcc/x86_64-suse-linux/10/../../../../x86_64-suse-linux/lib /usr/lib /pro/local/lib /lib/../lib64 /usr/lib/../lib64 /lib /lib64 /usr/lib64 /usr/local/lib64 -- libs=-lpthread -lnsl -lgdbm -ldb -ldl -lm -lcrypt -lutil -lc -lgdbm_compat -- perllibs=-lpthread -lnsl -ldl -lm -lcrypt -lutil -lc -+ libs=-lpthread -lgdbm -ldb -ldl -lm -lcrypt -lutil -lc -lgdbm_compat -+ perllibs=-lpthread -ldl -lm -lcrypt -lutil -lc - libc=libc-2.31.so - so=so - useshrplib=true -diff --git a/plan9/config_sh.sample b/plan9/config_sh.sample -index b761363..ad711d5 100644 ---- a/plan9/config_sh.sample -+++ b/plan9/config_sh.sample -@@ -857,7 +857,7 @@ libsdirs='' - libsfiles='' - libsfound='' - libspath=' /lib' --libswanted='socket bind inet nsl nm ndbm gdbm dbm db malloc dl ld sun m c cposix posix ndir dir crypt sec ucb bsd BSD PW x util' -+libswanted='socket bind inet nm ndbm gdbm dbm db malloc dl ld sun m c cposix posix ndir dir crypt sec ucb bsd BSD PW x util' - libswanted_uselargefiles='' - line='' - lint='' -diff --git a/pod/perlrun.pod b/pod/perlrun.pod -index 5d3aa3e..e632e0a 100644 ---- a/pod/perlrun.pod -+++ b/pod/perlrun.pod -@@ -895,11 +895,11 @@ non-letters). For example: - $ perl -V:libc - libc='/lib/libc-2.2.4.so'; - $ perl -V:lib. -- libs='-lnsl -lgdbm -ldb -ldl -lm -lcrypt -lutil -lc'; -+ libs='-lgdbm -ldb -ldl -lm -lcrypt -lutil -lc'; - libc='/lib/libc-2.2.4.so'; - $ perl -V:lib.* - libpth='/usr/local/lib /lib /usr/lib'; -- libs='-lnsl -lgdbm -ldb -ldl -lm -lcrypt -lutil -lc'; -+ libs='-lgdbm -ldb -ldl -lm -lcrypt -lutil -lc'; - lib_ext='.a'; - libc='/lib/libc-2.2.4.so'; - libperl='libperl.a'; -diff --git a/win32/config.gc b/win32/config.gc -index af6fed9..111d4ad 100644 ---- a/win32/config.gc -+++ b/win32/config.gc -@@ -869,8 +869,8 @@ libsdirs='' - libsfiles='' - libsfound='' - libspath='' --libswanted='net socket inet nsl nm ndbm gdbm dbm db malloc dl ld sun m c cposix posix ndir dir crypt ucb bsd BSD PW x' --libswanted_uselargefiles='net socket inet nsl nm ndbm gdbm dbm db malloc dl ld sun m c cposix posix ndir dir crypt ucb bsd BSD PW x' -+libswanted='net socket inet nm ndbm gdbm dbm db malloc dl ld sun m c cposix posix ndir dir crypt ucb bsd BSD PW x' -+libswanted_uselargefiles='net socket inet nm ndbm gdbm dbm db malloc dl ld sun m c cposix posix ndir dir crypt ucb bsd BSD PW x' - line='line' - lint='' - lkflags='' -diff --git a/win32/config.vc b/win32/config.vc -index f4625bf..cfa1c8a 100644 ---- a/win32/config.vc -+++ b/win32/config.vc -@@ -868,8 +868,8 @@ libsdirs='' - libsfiles='' - libsfound='' - libspath='' --libswanted='net socket inet nsl nm ndbm gdbm dbm db malloc dl ld sun m c cposix posix ndir dir crypt ucb bsd BSD PW x' --libswanted_uselargefiles='net socket inet nsl nm ndbm gdbm dbm db malloc dl ld sun m c cposix posix ndir dir crypt ucb bsd BSD PW x' -+libswanted='net socket inet nm ndbm gdbm dbm db malloc dl ld sun m c cposix posix ndir dir crypt ucb bsd BSD PW x' -+libswanted_uselargefiles='net socket inet nm ndbm gdbm dbm db malloc dl ld sun m c cposix posix ndir dir crypt ucb bsd BSD PW x' - line='line' - lint='' - lkflags='' diff --git a/omnibus/config/patches/pkg-config/openbsd-charset.patch b/omnibus/config/patches/pkg-config/openbsd-charset.patch deleted file mode 100644 index d41dbde19..000000000 --- a/omnibus/config/patches/pkg-config/openbsd-charset.patch +++ /dev/null @@ -1,19 +0,0 @@ ---- pkg-config-0.28.orig/glib/glib/libcharset/config.charset Wed May 13 18:21:29 2015 -+++ pkg-config-0.28/glib/glib/libcharset/config.charset Wed May 13 18:21:54 2015 -@@ -398,6 +398,16 @@ - echo "BIG5 BIG5" - echo "SJIS SHIFT_JIS" - ;; -+ openbsd*) -+ echo "646 ASCII" -+ echo "ISO8859-1 ISO-8859-1" -+ echo "ISO8859-2 ISO-8859-2" -+ echo "ISO8859-4 ISO-8859-4" -+ echo "ISO8859-5 ISO-8859-5" -+ echo "ISO8859-7 ISO-8859-7" -+ echo "ISO8859-13 ISO-8859-13" -+ echo "ISO8859-15 ISO-8859-15" -+ ;; - darwin[56]*) - # Darwin 6.8 doesn't have nl_langinfo(CODESET); therefore - # localcharset.c falls back to using the full locale name diff --git a/omnibus/config/patches/postgresql/no_docs.patch b/omnibus/config/patches/postgresql/no_docs.patch deleted file mode 100644 index 227c47d90..000000000 --- a/omnibus/config/patches/postgresql/no_docs.patch +++ /dev/null @@ -1,19 +0,0 @@ ---- GNUmakefile.in.original 2016-12-19 06:01:36.664961781 -0500 -+++ GNUmakefile.in 2016-12-19 06:02:15.872961781 -0500 -@@ -16,7 +16,7 @@ - docs: - $(MAKE) -C doc all - --$(call recurse,world,doc src config contrib,all) -+$(call recurse,world,src config contrib,all) - world: - +@echo "PostgreSQL, contrib, and documentation successfully made. Ready to install." - -@@ -32,7 +32,7 @@ - install-docs: - $(MAKE) -C doc install - --$(call recurse,install-world,doc src config contrib,install) -+$(call recurse,install-world,src config contrib,install) - install-world: - +@echo "PostgreSQL, contrib, and documentation installation complete." diff --git a/omnibus/config/patches/python/disable_modules.patch b/omnibus/config/patches/python/disable_modules.patch deleted file mode 100644 index 5271bc873..000000000 --- a/omnibus/config/patches/python/disable_modules.patch +++ /dev/null @@ -1,14 +0,0 @@ -diff --git a/Setup b/Setup.new -index 02cfb67..26342ef 100644 ---- a/Setup -+++ b/Setup.new -@@ -366,7 +366,8 @@ xxsubtype xxsubtype.c - # Uncommenting the following line tells makesetup that all following modules - # are not built (see above for more detail). - # --#*disabled* -+*disabled* -+nis _sqlite3 _gdbm _dbm - # - #_sqlite3 _tkinter _curses pyexpat - #_codecs_jp _codecs_kr _codecs_tw unicodedata diff --git a/omnibus/config/patches/readline/8.1.patch b/omnibus/config/patches/readline/8.1.patch deleted file mode 100644 index 70a67aae5..000000000 --- a/omnibus/config/patches/readline/8.1.patch +++ /dev/null @@ -1,75 +0,0 @@ -*** ../readline-8.1-patched/bind.c 2020-10-26 10:03:14.000000000 -0400 ---- bind.c 2021-01-18 16:38:48.000000000 -0500 -*************** -*** 1235,1239 **** - else if (_rl_strnicmp (args, "version", 7) == 0) - { -! int rlversion, versionarg, op, previ, major, minor; - - _rl_parsing_conditionalized_out = 1; ---- 1235,1239 ---- - else if (_rl_strnicmp (args, "version", 7) == 0) - { -! int rlversion, versionarg, op, previ, major, minor, opresult; - - _rl_parsing_conditionalized_out = 1; -*************** -*** 1295,1316 **** - { - case OP_EQ: -! _rl_parsing_conditionalized_out = rlversion == versionarg; - break; - case OP_NE: -! _rl_parsing_conditionalized_out = rlversion != versionarg; - break; - case OP_GT: -! _rl_parsing_conditionalized_out = rlversion > versionarg; - break; - case OP_GE: -! _rl_parsing_conditionalized_out = rlversion >= versionarg; - break; - case OP_LT: -! _rl_parsing_conditionalized_out = rlversion < versionarg; - break; - case OP_LE: -! _rl_parsing_conditionalized_out = rlversion <= versionarg; - break; - } - } - /* Check to see if the first word in ARGS is the same as the ---- 1295,1317 ---- - { - case OP_EQ: -! opresult = rlversion == versionarg; - break; - case OP_NE: -! opresult = rlversion != versionarg; - break; - case OP_GT: -! opresult = rlversion > versionarg; - break; - case OP_GE: -! opresult = rlversion >= versionarg; - break; - case OP_LT: -! opresult = rlversion < versionarg; - break; - case OP_LE: -! opresult = rlversion <= versionarg; - break; - } -+ _rl_parsing_conditionalized_out = 1 - opresult; - } - /* Check to see if the first word in ARGS is the same as the - -*** ../readline-8.1/patchlevel 2013-11-15 08:11:11.000000000 -0500 ---- patchlevel 2014-03-21 08:28:40.000000000 -0400 -*************** -*** 1,3 **** - # Do not edit -- exists only for use by patch - -! 0 ---- 1,3 ---- - # Do not edit -- exists only for use by patch - -! 1 diff --git a/omnibus/config/patches/ruby/patch-configure b/omnibus/config/patches/ruby/patch-configure deleted file mode 100644 index e4b239e02..000000000 --- a/omnibus/config/patches/ruby/patch-configure +++ /dev/null @@ -1,103 +0,0 @@ -$NetBSD: patch-configure,v 1.4 2012/10/12 14:51:31 taca Exp $ - -* Adding Interix and MirBSD support. -* Ignore doxygen. - ---- configure.orig 2012-10-12 09:23:46.000000000 +0000 -+++ configure -@@ -10654,6 +10654,9 @@ esac - superux*) : - ac_cv_func_setitimer=no - ;; #( -+ interix*) LIBS="-lm $LIBS" -+ ac_cv_func_getpgrp_void=yes -+ ;; #( - *) : - LIBS="-lm $LIBS" ;; - esac -@@ -11980,6 +11983,9 @@ fi - ac_fn_c_check_type "$LINENO" "struct timespec" "ac_cv_type_struct_timespec" "#ifdef HAVE_TIME_H - #include - #endif -+#ifdef HAVE_SYS_TIME_H -+# include -+#endif - " - if test "x$ac_cv_type_struct_timespec" = xyes; then : - -@@ -15790,7 +15796,7 @@ done - MAINLIBS="-pthread $MAINLIBS" ;; #( - *) : - case "$target_os" in #( -- openbsd*) : -+ openbsd*|mirbsd*) : - LIBS="-pthread $LIBS" ;; #( - *) : - LIBS="-l$pthread_lib $LIBS" ;; -@@ -16239,8 +16245,12 @@ esac ;; #( - rb_cv_dlopen=yes ;; #( - interix*) : - : ${LDSHARED='$(CC) -shared'} -+ LDFLAGS="$LDFLAGS -Wl,-E" - XLDFLAGS="$XLDFLAGS -Wl,-E" -+ # use special random-slot linkage in 0x[56]XXXXXXX - LIBPATHFLAG=" -L%1\$-s" -+ DLDFLAGS="$DLDFLAGS "'-Wl,-h,$(.TARGET) -Wl,--image-base,$$(($$RANDOM %4096/2*262144+1342177280))' -+ RPATHFLAG=' -Wl,-R%1$-s' - rb_cv_dlopen=yes ;; #( - freebsd*|dragonfly*) : - -@@ -16252,7 +16262,7 @@ esac ;; #( - test "$GCC" = yes && test "$rb_cv_prog_gnu_ld" = yes || LDSHARED="ld -Bshareable" - fi - rb_cv_dlopen=yes ;; #( -- openbsd*) : -+ openbsd*|mirbsd*) : - : ${LDSHARED='$(CC) -shared ${CCDLFLAGS}'} - if test "$rb_cv_binary_elf" = yes; then - LDFLAGS="$LDFLAGS -Wl,-E" -@@ -16781,7 +16791,7 @@ _ACEOF - freebsd*|dragonfly*) : - - SOLIBS='$(LIBS)' -- LIBRUBY_SO='lib$(RUBY_SO_NAME).so.$(MAJOR)$(MINOR)' -+ LIBRUBY_SO='lib$(RUBY_SO_NAME).so.$(MAJOR)$(MINOR)$(TEENY)' - if test "$rb_cv_binary_elf" != "yes" ; then - LIBRUBY_SO="$LIBRUBY_SO.\$(TEENY)" - LIBRUBY_ALIASES='' -@@ -16798,7 +16808,7 @@ _ACEOF - LIBRUBY_ALIASES="" - fi - ;; #( -- openbsd*) : -+ openbsd*|mirbsd*) : - - SOLIBS='$(LIBS)' - LIBRUBY_SO='lib$(RUBY_SO_NAME).so.$(MAJOR).'`expr ${MINOR} \* 10 + ${TEENY}` -@@ -16859,7 +16869,12 @@ esac - ;; #( - interix*) : - -- LIBRUBYARG_SHARED='-L. -L${libdir} -l$(RUBY_SO_NAME)' -+ SOLIBS='$(LIBS)' -+ LIBRUBY_SO='lib$(RUBY_SO_NAME).so.$(MAJOR)$(MINOR).$(TEENY)' -+ # link explicitly to 0x48000000 -+ LIBRUBY_DLDFLAGS='-Wl,-h,lib$(RUBY_SO_NAME).so.$(MAJOR)$(MINOR) -Wl,--image-base,1207959552' -+ LIBRUBYARG_SHARED='-Wl,-R -Wl,${libdir} -L${libdir} -L. -l$(RUBY_SO_NAME)' -+ LIBRUBY_ALIASES='lib$(RUBY_SO_NAME).so.$(MAJOR)$(MINOR) lib$(RUBY_SO_NAME).so' - ;; #( - *) : - ;; -@@ -16922,11 +16937,7 @@ if test "$install_doc" != no; then - else - RDOCTARGET="nodoc" - fi -- if test "$install_capi" != no -a -n "$DOXYGEN"; then -- CAPITARGET="capi" -- else -- CAPITARGET="nodoc" -- fi -+ CAPITARGET="nodoc" - else - RDOCTARGET="nodoc" - CAPITARGET="nodoc" diff --git a/omnibus/config/patches/ruby/ruby-aix-atomic.patch b/omnibus/config/patches/ruby/ruby-aix-atomic.patch deleted file mode 100644 index 0ed17ef93..000000000 --- a/omnibus/config/patches/ruby/ruby-aix-atomic.patch +++ /dev/null @@ -1,11 +0,0 @@ ---- ruby-2.1.2/ruby_atomic.h.orig 2014-09-29 14:08:29.000000000 -0500 -+++ ruby-2.1.2/ruby_atomic.h 2014-09-29 14:08:41.000000000 -0500 -@@ -117,7 +117,7 @@ - # endif - - #else --typedef int rb_atomic_t; -+typedef long rb_atomic_t; - #define NEED_RUBY_ATOMIC_OPS - extern rb_atomic_t ruby_atomic_exchange(rb_atomic_t *ptr, rb_atomic_t val); - extern rb_atomic_t ruby_atomic_compare_and_swap(rb_atomic_t *ptr, diff --git a/omnibus/config/patches/ruby/ruby-aix-configure.patch b/omnibus/config/patches/ruby/ruby-aix-configure.patch deleted file mode 100644 index f6ef4bb0b..000000000 --- a/omnibus/config/patches/ruby/ruby-aix-configure.patch +++ /dev/null @@ -1,20 +0,0 @@ ---- ruby-1.9.3-p547/configure.orig 2014-05-16 09:38:31 -0500 -+++ ruby-1.9.3-p547/configure 2014-07-15 19:58:29 -0500 -@@ -16488,6 +16488,7 @@ - aix*) : - : ${LDSHARED='$(CC)'} - LDSHARED="$LDSHARED ${linker_flag}-G" -+ DLDFLAGS='-eInit_$(TARGET)' - EXTDLDFLAGS='-e$(TARGET_ENTRY)' - XLDFLAGS="${linker_flag}"'-bE:$(ARCHFILE)'" ${linker_flag}-brtl" - XLDFLAGS="$XLDFLAGS ${linker_flag}-blibpath:${prefix}/lib:${LIBPATH:-/usr/lib:/lib}" -@@ -17028,7 +17029,8 @@ - - LIBRUBY_DLDFLAGS="${linker_flag}-bnoentry $XLDFLAGS" - LIBRUBYARG_SHARED='-L${libdir} -l${RUBY_SO_NAME}' -- SOLIBS='-lm -lc' -+ SOLIBS='-lm -lc -lz' -+ LIBRUBY_SO='lib$(RUBY_SO_NAME).a' - ;; #( - beos*) : - diff --git a/omnibus/config/patches/ruby/ruby-aix-vm-core.patch b/omnibus/config/patches/ruby/ruby-aix-vm-core.patch deleted file mode 100644 index 773a28772..000000000 --- a/omnibus/config/patches/ruby/ruby-aix-vm-core.patch +++ /dev/null @@ -1,14 +0,0 @@ ---- ruby-2.1.2/vm_core.h.orig 2014-09-29 14:05:24.000000000 -0500 -+++ ruby-2.1.2/vm_core.h 2014-09-29 14:05:39.000000000 -0500 -@@ -392,9 +392,9 @@ - - /* postponed_job */ - struct rb_postponed_job_struct *postponed_job_buffer; -- int postponed_job_index; -+ long postponed_job_index; - -- int src_encoding_index; -+ long src_encoding_index; - - VALUE verbose, debug, orig_progname, progname; - VALUE coverages; diff --git a/omnibus/config/patches/ruby/ruby-disable-copy-file-range.patch b/omnibus/config/patches/ruby/ruby-disable-copy-file-range.patch deleted file mode 100644 index d2ceaa8d2..000000000 --- a/omnibus/config/patches/ruby/ruby-disable-copy-file-range.patch +++ /dev/null @@ -1,13 +0,0 @@ -diff --git a/io.c b/io.c -index 868756ffc5..2e4166d664 100644 ---- a/io.c -+++ b/io.c -@@ -10887,7 +10887,7 @@ nogvl_copy_stream_wait_write(struct copy_stream_struct *stp) - return 0; - } - --#if defined HAVE_COPY_FILE_RANGE || (defined __linux__ && defined __NR_copy_file_range) -+#if 0 - # define USE_COPY_FILE_RANGE - #endif - diff --git a/omnibus/config/patches/ruby/ruby-fix-reserve-stack-segfault.patch b/omnibus/config/patches/ruby/ruby-fix-reserve-stack-segfault.patch deleted file mode 100644 index ee61dd6df..000000000 --- a/omnibus/config/patches/ruby/ruby-fix-reserve-stack-segfault.patch +++ /dev/null @@ -1,12 +0,0 @@ ---- a/thread_pthread.c -+++ b/thread_pthread.c -@@ -686,8 +686,8 @@ reserve_stack(volatile char *limit, size_t size) - limit -= size; - if (buf > limit) { - limit = alloca(buf - limit); -+ limit[0] = 0; /* ensure alloca is called */ - limit -= stack_check_margin; -- limit[0] = 0; - } - } - } diff --git a/omnibus/config/patches/ruby/ruby-freebsd-9-zlib.patch b/omnibus/config/patches/ruby/ruby-freebsd-9-zlib.patch deleted file mode 100644 index e69de29bb..000000000 diff --git a/omnibus/config/patches/ruby/ruby-mkmf.patch b/omnibus/config/patches/ruby/ruby-mkmf.patch deleted file mode 100644 index aef3b0446..000000000 --- a/omnibus/config/patches/ruby/ruby-mkmf.patch +++ /dev/null @@ -1,29 +0,0 @@ ---- a/lib/mkmf.rb 2016-06-16 16:19:13.000000000 -0400 -+++ b/lib/mkmf.rb 2016-06-16 16:23:08.000000000 -0400 -@@ -365,6 +365,17 @@ - end - - def libpath_env -+ # Patch for aix -+ # Ideally applications should not need LIBPATH/LD_LIBRARY_PATH set -+ # and should rely on the embedded paths in binaries/shared objects -+ # For chef say on AIX we already build using -blibpath and -+ # LD_RUN_PATH, so the extensions built using chef embedded ruby -+ # (using rbconfig) should have correct paths set. -+ # Setting LIBPATH overrides the behaviour of programs invoked from -+ # chef built ruby, for example xlc ends up picking up libiconv built -+ # within chef embedded ruby libs instead of the one from /usr/lib -+ return {} -+ - # used only if native compiling - if libpathenv = config_string("LIBPATHENV") - pathenv = ENV[libpathenv] -@@ -1799,7 +1810,7 @@ - # - if !CROSS_COMPILING - case CONFIG['build_os'] -- when 'mingw32' -+ when 'mingw32', 'mingw64' - def mkintpath(path) - # mingw uses make from msys and it needs special care - # converts from C:\some\path to /C/some/path diff --git a/omnibus/config/patches/ruby/ruby-no-stack-protector.patch b/omnibus/config/patches/ruby/ruby-no-stack-protector.patch deleted file mode 100644 index 7ecabf32f..000000000 --- a/omnibus/config/patches/ruby/ruby-no-stack-protector.patch +++ /dev/null @@ -1,13 +0,0 @@ -diff --git a/configure.dist b/configure -index d83c15a..bd4813c 100755 ---- a/configure.dist -+++ b/configure -@@ -7491,7 +7491,7 @@ main () - } - _ACEOF - if ac_fn_c_try_compile "$LINENO"; then : -- stack_protector=yes -+ stack_protector=no - { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 - $as_echo "yes" >&6; } - else diff --git a/omnibus/config/patches/ruby/ruby-openssl-1.0.1c.patch b/omnibus/config/patches/ruby/ruby-openssl-1.0.1c.patch deleted file mode 100644 index 7b98d226c..000000000 --- a/omnibus/config/patches/ruby/ruby-openssl-1.0.1c.patch +++ /dev/null @@ -1,42 +0,0 @@ -diff -Naur ruby-1.9.3-p286.pristine/ext/openssl/openssl_missing.c ruby-1.9.3-p286/ext/openssl/openssl_missing.c ---- ruby-1.9.3-p286.pristine/ext/openssl/openssl_missing.c 2011-06-26 01:32:03.000000000 +0000 -+++ ruby-1.9.3-p286/ext/openssl/openssl_missing.c 2013-01-28 05:08:38.192083253 +0000 -@@ -22,7 +22,7 @@ - #include "openssl_missing.h" - - #if !defined(HAVE_HMAC_CTX_COPY) --void -+int - HMAC_CTX_copy(HMAC_CTX *out, HMAC_CTX *in) - { - if (!out || !in) return; -@@ -118,7 +118,7 @@ - * tested on 0.9.7d. - */ - int --EVP_CIPHER_CTX_copy(EVP_CIPHER_CTX *out, EVP_CIPHER_CTX *in) -+EVP_CIPHER_CTX_copy(EVP_CIPHER_CTX *out, const EVP_CIPHER_CTX *in) - { - memcpy(out, in, sizeof(EVP_CIPHER_CTX)); - -diff -Naur ruby-1.9.3-p286.pristine/ext/openssl/openssl_missing.h ruby-1.9.3-p286/ext/openssl/openssl_missing.h ---- ruby-1.9.3-p286.pristine/ext/openssl/openssl_missing.h 2011-06-26 01:32:03.000000000 +0000 -+++ ruby-1.9.3-p286/ext/openssl/openssl_missing.h 2013-01-28 05:08:38.192500215 +0000 -@@ -68,7 +68,7 @@ - #endif - - #if !defined(HAVE_HMAC_CTX_COPY) --void HMAC_CTX_copy(HMAC_CTX *out, HMAC_CTX *in); -+int HMAC_CTX_copy(HMAC_CTX *out, HMAC_CTX *in); - #endif - - #if !defined(HAVE_HMAC_CTX_CLEANUP) -@@ -92,7 +92,7 @@ - #endif - - #if !defined(HAVE_EVP_CIPHER_CTX_COPY) --int EVP_CIPHER_CTX_copy(EVP_CIPHER_CTX *out, EVP_CIPHER_CTX *in); -+int EVP_CIPHER_CTX_copy(EVP_CIPHER_CTX *out, const EVP_CIPHER_CTX *in); - #endif - - #if !defined(HAVE_EVP_DIGESTINIT_EX) diff --git a/omnibus/config/patches/ruby/ruby-solaris-linux-socket-compat.patch b/omnibus/config/patches/ruby/ruby-solaris-linux-socket-compat.patch deleted file mode 100644 index 7369c1def..000000000 --- a/omnibus/config/patches/ruby/ruby-solaris-linux-socket-compat.patch +++ /dev/null @@ -1,42 +0,0 @@ ---- ruby-2.1.5/ext/socket/raddrinfo.c.orig Fri Mar 20 13:53:18 2015 -+++ ruby-2.1.5/ext/socket/raddrinfo.c Fri Mar 20 13:53:34 2015 -@@ -8,6 +8,39 @@ - - ************************************************/ - -+/* Linux kernel socket model compat defs. -+ AIX/Solaris/HP-UX all use an alternate -+ interface called DLPI. See the below and -+ libpcap's pcap-dlpi.c for more info: -+ http://www.oracle.com/technetwork/server-storage/solaris/solaris-linux-app-139382.html*/ -+#define PACKET_HOST 0 /* To us. */ -+#define PACKET_BROADCAST 1 /* To all. */ -+#define PACKET_MULTICAST 2 /* To group. */ -+#define PACKET_OTHERHOST 3 /* To someone else. */ -+#define PACKET_OUTGOING 4 /* Originated by us . */ -+#define PACKET_LOOPBACK 5 -+#define PACKET_FASTROUTE 6 -+ -+/* Packet socket options. */ -+ -+#define PACKET_ADD_MEMBERSHIP 1 -+#define PACKET_DROP_MEMBERSHIP 2 -+#define PACKET_RECV_OUTPUT 3 -+#define PACKET_RX_RING 5 -+#define PACKET_STATISTICS 6 -+ -+struct packet_mreq -+ { -+ int mr_ifindex; -+ unsigned short int mr_type; -+ unsigned short int mr_alen; -+ unsigned char mr_address[8]; -+ }; -+ -+#define PACKET_MR_MULTICAST 0 -+#define PACKET_MR_PROMISC 1 -+#define PACKET_MR_ALLMULTI 2 -+ - #include "rubysocket.h" - - #if defined(INET6) && (defined(LOOKUP_ORDER_HACK_INET) || defined(LOOKUP_ORDER_HACK_INET6)) diff --git a/omnibus/config/patches/ruby/ruby-sparc-1.9.3-c99.patch b/omnibus/config/patches/ruby/ruby-sparc-1.9.3-c99.patch deleted file mode 100644 index c7ac38b59..000000000 --- a/omnibus/config/patches/ruby/ruby-sparc-1.9.3-c99.patch +++ /dev/null @@ -1,20 +0,0 @@ ---- ruby-1.9.3/sparc.c_orig Wed Apr 22 19:07:16 2015 -+++ ruby-1.9.3/sparc.c Wed Apr 22 19:07:57 2015 -@@ -11,7 +11,16 @@ - *********************************************************************/ - void rb_sparc_flush_register_windows(void) - { -- asm -+ /* -+ * gcc doesn't provide "asm" keyword if -ansi and the various -std options -+ * are given. -+ * http://gcc.gnu.org/onlinedocs/gcc/Alternate-Keywords.html -+ */ -+#ifndef __GNUC__ -+#define __asm__ asm -+#endif -+ -+ __asm__ - #ifdef __GNUC__ - __volatile__ - #endif diff --git a/omnibus/config/patches/ruby/ruby_aix_1_9_3_448_ssl_EAGAIN.patch b/omnibus/config/patches/ruby/ruby_aix_1_9_3_448_ssl_EAGAIN.patch deleted file mode 100644 index ec661262b..000000000 --- a/omnibus/config/patches/ruby/ruby_aix_1_9_3_448_ssl_EAGAIN.patch +++ /dev/null @@ -1,58 +0,0 @@ -diff --git a/ext/openssl/lib/openssl/ssl-internal.rb b/ext/openssl/lib/openssl/ssl-internal.rb -index 356d4e8..89a7a42 100644 ---- a/ext/openssl/lib/openssl/ssl-internal.rb -+++ b/ext/openssl/lib/openssl/ssl-internal.rb -@@ -169,7 +169,15 @@ module OpenSSL - begin - ssl = OpenSSL::SSL::SSLSocket.new(sock, @ctx) - ssl.sync_close = true -- ssl.accept if @start_immediately -+ if @start_immediately -+ # Retry on EAGAIN (may be due to underlying inprogress for TLS handshake or renegotiation requested.) -+ # Any other error is rescued further. -+ begin -+ ssl.accept -+ rescue Errno::EAGAIN -+ retry -+ end -+ end - ssl - rescue SSLError => ex - sock.close -diff --git a/lib/net/http.rb b/lib/net/http.rb -index 9e4fe6a..41a9c75 100644 ---- a/lib/net/http.rb -+++ b/lib/net/http.rb -@@ -797,7 +797,14 @@ module Net #:nodoc: - end - # Server Name Indication (SNI) RFC 3546 - s.hostname = @address if s.respond_to? :hostname= -- timeout(@open_timeout) { s.connect } -+ timeout(@open_timeout) { -+ # Retry on EAGAIN (may be due to underlying inprogress for TLS handshake or renegotiation requested.) -+ begin -+ s.connect -+ rescue Errno::EAGAIN -+ retry -+ end -+ } - if @ssl_context.verify_mode != OpenSSL::SSL::VERIFY_NONE - s.post_connection_check(@address) - end -diff --git a/lib/net/protocol.rb b/lib/net/protocol.rb -index f374466..b6f9f17 100644 ---- a/lib/net/protocol.rb -+++ b/lib/net/protocol.rb -@@ -153,6 +153,12 @@ module Net # :nodoc: - else - raise Timeout::Error - end -+ rescue Errno::EAGAIN -+ # read_nonblock calls underlying SSL_read. openssl doc states that data can be processed only when SSL/TLS -+ # record has been received completely. Also data that was not retrieved at the last call of SSL_read() -+ # can still be buffered inside the SSL layer and will be retrieved on the next call to SSL_read. -+ # http://www.openssl.org/docs/ssl/SSL_read.html -+ retry - end - end - diff --git a/omnibus/config/patches/ruby/ruby_aix_2_1_3_ssl_EAGAIN.patch b/omnibus/config/patches/ruby/ruby_aix_2_1_3_ssl_EAGAIN.patch deleted file mode 100644 index a5eacc994..000000000 --- a/omnibus/config/patches/ruby/ruby_aix_2_1_3_ssl_EAGAIN.patch +++ /dev/null @@ -1,19 +0,0 @@ ---- ruby-2.1.3/ext/openssl/lib/openssl/ssl.rb_orig 2014-10-24 13:09:44.000000000 -0500 -+++ ruby-2.1.3/ext/openssl/lib/openssl/ssl.rb 2014-10-24 13:11:01.000000000 -0500 -@@ -194,7 +194,15 @@ - begin - ssl = OpenSSL::SSL::SSLSocket.new(sock, @ctx) - ssl.sync_close = true -- ssl.accept if @start_immediately -+ if @start_immediately -+ # Retry on EAGAIN (may be due to underlying inprogress for TLS handshake or renegotiation requested.) -+ # Any other error is rescued further. -+ begin -+ ssl.accept -+ rescue Errno::EAGAIN -+ retry -+ end -+ end - ssl - rescue SSLError => ex - sock.close diff --git a/omnibus/config/patches/ruby/ruby_aix_openssl.patch b/omnibus/config/patches/ruby/ruby_aix_openssl.patch deleted file mode 100644 index e8204b49d..000000000 --- a/omnibus/config/patches/ruby/ruby_aix_openssl.patch +++ /dev/null @@ -1,10 +0,0 @@ ---- ruby-1.9.3-p547/ext/openssl/extconf.rb.orig 2014-07-15 17:50:30 -0500 -+++ ruby-1.9.3-p547/ext/openssl/extconf.rb 2014-07-15 17:50:39 -0500 -@@ -34,6 +34,7 @@ - end - - Logging::message "=== Checking for system dependent stuff... ===\n" -+have_library("z", "inflate") - have_library("nsl", "t_open") - have_library("socket", "socket") - have_header("assert.h") diff --git a/omnibus/config/patches/ruby/rvm-cflags.patch b/omnibus/config/patches/ruby/rvm-cflags.patch deleted file mode 100644 index fcd2f6d77..000000000 --- a/omnibus/config/patches/ruby/rvm-cflags.patch +++ /dev/null @@ -1,27 +0,0 @@ ---- a/configure.in -+++ b/configure.in -@@ -267,11 +267,9 @@ - cflagspat="$cflagspat;s|"`eval echo '"'"${debugflags}"'"' | sed 's/[[][|.*]]/\\&/g;s/^ */ /;s/ *$/ /'`'| |g' - test -z "warnflags" || - cflagspat="$cflagspat;s|"`eval echo '"'"${warnflags}"'"' | sed 's/[[][|.*]]/\\&/g;s/^ */ /;s/ *$/ /'`'| |g' --if test -z "${CFLAGS+set}"; then -- cflags=`echo " $cflags " | sed "$cflagspat;s/^ *//;s/ *$//"` -- orig_cflags="$cflags" -- cflags="$cflags "'${optflags} ${debugflags} ${warnflags}' --fi -+cflags=`echo " $cflags " | sed "$cflagspat;s/^ *//;s/ *$//"` -+orig_cflags="$cflags" -+cflags="$cflags "'${optflags} ${debugflags} ${warnflags}' - if test -z "${CXXFLAGS+set}"; then - cxxflags=`echo " $cxxflags " | sed "$cflagspat;s/^ *//;s/ *$//"` - orig_cxxflags="$cxxflags" -@@ -511,7 +509,8 @@ - ]) - fi - --test -z "${ac_env_CFLAGS_set}" -a -n "${cflags+set}" && eval CFLAGS="\"$cflags $ARCH_FLAG\"" -+test -z "${ac_env_CFLAGS_set}" && CFLAGS="$ARCH_FLAG" -+test -n "${cflags:+set}" && eval CFLAGS="\"$cflags\${CFLAGS:+ $CFLAGS}\"" - test -z "${ac_env_CXXFLAGS_set}" -a -n "${cxxflags+set}" && eval CXXFLAGS="\"$cxxflags $ARCH_FLAG\"" - - dnl check for large file stuff diff --git a/omnibus/config/patches/ruby/thread-memory-allocations-2.7.patch b/omnibus/config/patches/ruby/thread-memory-allocations-2.7.patch deleted file mode 100644 index 239e96bc5..000000000 --- a/omnibus/config/patches/ruby/thread-memory-allocations-2.7.patch +++ /dev/null @@ -1,256 +0,0 @@ -From 97f14ebfd8d24d71e10c450e0a90b6322f9c0d59 Mon Sep 17 00:00:00 2001 -From: =?UTF-8?q?Kamil=20Trzci=C5=84ski?= -Date: Tue, 22 Dec 2020 15:33:08 +0100 -Subject: [PATCH] Expose `Thread#memory_allocations` counters - -This provides currently a per-thread GC heap slots -and malloc allocations statistics. - -This is designed to measure a memory allocations -in a multi-threaded environments (concurrent requests -processing) with an accurate information about allocated -memory within a given execution context. - -Example: Measure memory pressure generated by a given -requests to easier find requests with a lot of allocations. ---- - gc.c | 20 ++++++ - .../test_thread_trace_memory_allocations.rb | 67 +++++++++++++++++++ - thread.c | 55 +++++++++++++++ - vm_core.h | 17 +++++ - 4 files changed, 159 insertions(+) - create mode 100644 test/ruby/test_thread_trace_memory_allocations.rb - -diff --git a/gc.c b/gc.c -index 73faf46b128b..f2dcd2935052 100644 ---- a/gc.c -+++ b/gc.c -@@ -2172,6 +2172,13 @@ newobj_init(VALUE klass, VALUE flags, VALUE v1, VALUE v2, VALUE v3, int wb_prote - GC_ASSERT(!SPECIAL_CONST_P(obj)); /* check alignment */ - #endif - -+#if THREAD_TRACE_MEMORY_ALLOCATIONS -+ rb_thread_t *th = ruby_threadptr_for_trace_memory_allocations(); -+ if (th) { -+ ATOMIC_SIZE_INC(th->memory_allocations.total_allocated_objects); -+ } -+#endif -+ - objspace->total_allocated_objects++; - - gc_report(5, objspace, "newobj: %s\n", obj_info(obj)); -@@ -9732,6 +9739,19 @@ objspace_malloc_increase(rb_objspace_t *objspace, void *mem, size_t new_size, si - #endif - } - -+#if THREAD_TRACE_MEMORY_ALLOCATIONS -+ rb_thread_t *th = ruby_threadptr_for_trace_memory_allocations(); -+ if (th) { -+ if (new_size > old_size) { -+ ATOMIC_SIZE_ADD(th->memory_allocations.total_malloc_bytes, new_size - old_size); -+ } -+ -+ if (type == MEMOP_TYPE_MALLOC) { -+ ATOMIC_SIZE_INC(th->memory_allocations.total_mallocs); -+ } -+ } -+#endif -+ - if (type == MEMOP_TYPE_MALLOC) { - retry: - if (malloc_increase > malloc_limit && ruby_native_thread_p() && !dont_gc) { -diff --git a/test/ruby/test_thread_trace_memory_allocations.rb b/test/ruby/test_thread_trace_memory_allocations.rb -new file mode 100644 -index 000000000000..2e281513578b ---- /dev/null -+++ b/test/ruby/test_thread_trace_memory_allocations.rb -@@ -0,0 +1,67 @@ -+# frozen_string_literal: true -+ -+require 'test/unit' -+ -+class TestThreadTraceMemoryAllocations < Test::Unit::TestCase -+ def test_disabled_trace_memory_allocations -+ Thread.trace_memory_allocations = false -+ -+ assert_predicate Thread.current.memory_allocations, :nil? -+ end -+ -+ def test_enabled_trace_memory_allocations -+ Thread.trace_memory_allocations = true -+ -+ assert_not_nil(Thread.current.memory_allocations) -+ end -+ -+ def test_only_this_thread_allocations_are_counted -+ changed = { -+ total_allocated_objects: 1000, -+ total_malloc_bytes: 1_000_000, -+ total_mallocs: 100 -+ } -+ -+ Thread.trace_memory_allocations = true -+ -+ assert_less_than(changed) do -+ Thread.new do -+ assert_greater_than(changed) do -+ # This will allocate: 5k objects, 5k mallocs, 5MB -+ allocate(5000, 1000) -+ end -+ end.join -+ -+ # This will allocate: 50 objects, 50 mallocs, 500 bytes -+ allocate(50, 10) -+ end -+ end -+ -+ private -+ -+ def allocate(slots, bytes) -+ Array.new(slots).map do -+ '0' * bytes -+ end -+ end -+ -+ def assert_greater_than(keys) -+ before = Thread.current.memory_allocations -+ yield -+ after = Thread.current.memory_allocations -+ -+ keys.each do |key, by| -+ assert_operator(by, :<=, after[key]-before[key], "expected the #{key} to change more than #{by}") -+ end -+ end -+ -+ def assert_less_than(keys) -+ before = Thread.current.memory_allocations -+ yield -+ after = Thread.current.memory_allocations -+ -+ keys.each do |key, by| -+ assert_operator(by, :>, after[key]-before[key], "expected the #{key} to change less than #{by}") -+ end -+ end -+end -diff --git a/thread.c b/thread.c -index 708aaa471d99..d68a59e9f2d6 100644 ---- a/thread.c -+++ b/thread.c -@@ -5143,6 +5143,55 @@ rb_thread_backtrace_locations_m(int argc, VALUE *argv, VALUE thval) - return rb_vm_thread_backtrace_locations(argc, argv, thval); - } - -+#if THREAD_TRACE_MEMORY_ALLOCATIONS -+rb_thread_t * -+ruby_threadptr_for_trace_memory_allocations(void) -+{ -+ // The order of this checks is important due -+ // to how Ruby VM is initialized -+ if (GET_VM()->thread_trace_memory_allocations && GET_EC() != NULL) { -+ return GET_THREAD(); -+ } -+ -+ return NULL; -+} -+ -+static VALUE -+rb_thread_s_trace_memory_allocations(VALUE _) -+{ -+ return GET_THREAD()->vm->thread_trace_memory_allocations ? Qtrue : Qfalse; -+} -+ -+static VALUE -+rb_thread_s_trace_memory_allocations_set(VALUE self, VALUE val) -+{ -+ GET_THREAD()->vm->thread_trace_memory_allocations = RTEST(val); -+ return val; -+} -+ -+static VALUE -+rb_thread_memory_allocations(VALUE self) -+{ -+ rb_thread_t *th = rb_thread_ptr(self); -+ -+ if (!th->vm->thread_trace_memory_allocations) { -+ return Qnil; -+ } -+ -+ VALUE ret = rb_hash_new(); -+ -+ VALUE total_allocated_objects = ID2SYM(rb_intern_const("total_allocated_objects")); -+ VALUE total_malloc_bytes = ID2SYM(rb_intern_const("total_malloc_bytes")); -+ VALUE total_mallocs = ID2SYM(rb_intern_const("total_mallocs")); -+ -+ rb_hash_aset(ret, total_allocated_objects, SIZET2NUM(th->memory_allocations.total_allocated_objects)); -+ rb_hash_aset(ret, total_malloc_bytes, SIZET2NUM(th->memory_allocations.total_malloc_bytes)); -+ rb_hash_aset(ret, total_mallocs, SIZET2NUM(th->memory_allocations.total_mallocs)); -+ -+ return ret; -+} -+#endif -+ - /* - * Document-class: ThreadError - * -@@ -5230,6 +5279,12 @@ Init_Thread(void) - rb_define_method(rb_cThread, "to_s", rb_thread_to_s, 0); - rb_define_alias(rb_cThread, "inspect", "to_s"); - -+#if THREAD_TRACE_MEMORY_ALLOCATIONS -+ rb_define_singleton_method(rb_cThread, "trace_memory_allocations", rb_thread_s_trace_memory_allocations, 0); -+ rb_define_singleton_method(rb_cThread, "trace_memory_allocations=", rb_thread_s_trace_memory_allocations_set, 1); -+ rb_define_method(rb_cThread, "memory_allocations", rb_thread_memory_allocations, 0); -+#endif -+ - rb_vm_register_special_exception(ruby_error_stream_closed, rb_eIOError, - "stream closed in another thread"); - -diff --git a/vm_core.h b/vm_core.h -index 12c3ac377551..63cdf55fa6ed 100644 ---- a/vm_core.h -+++ b/vm_core.h -@@ -69,6 +69,13 @@ - # define VM_INSN_INFO_TABLE_IMPL 2 - #endif - -+/* -+ * track a per thread memory allocations -+ */ -+#ifndef THREAD_TRACE_MEMORY_ALLOCATIONS -+# define THREAD_TRACE_MEMORY_ALLOCATIONS 1 -+#endif -+ - #include "ruby/ruby.h" - #include "ruby/st.h" - -@@ -602,6 +609,7 @@ typedef struct rb_vm_struct { - unsigned int running: 1; - unsigned int thread_abort_on_exception: 1; - unsigned int thread_report_on_exception: 1; -+ unsigned int thread_trace_memory_allocations: 1; - - unsigned int safe_level_: 1; - int sleeper; -@@ -960,6 +968,14 @@ typedef struct rb_thread_struct { - - rb_thread_list_t *join_list; - -+#if THREAD_TRACE_MEMORY_ALLOCATIONS -+ struct { -+ size_t total_allocated_objects; -+ size_t total_malloc_bytes; -+ size_t total_mallocs; -+ } memory_allocations; -+#endif -+ - union { - struct { - VALUE proc; -@@ -1852,6 +1868,7 @@ void rb_threadptr_interrupt(rb_thread_t *th); - void rb_threadptr_unlock_all_locking_mutexes(rb_thread_t *th); - void rb_threadptr_pending_interrupt_clear(rb_thread_t *th); - void rb_threadptr_pending_interrupt_enque(rb_thread_t *th, VALUE v); -+rb_thread_t *ruby_threadptr_for_trace_memory_allocations(void); - VALUE rb_ec_get_errinfo(const rb_execution_context_t *ec); - void rb_ec_error_print(rb_execution_context_t * volatile ec, volatile VALUE errinfo); - void rb_execution_context_update(const rb_execution_context_t *ec); diff --git a/omnibus/config/patches/rubygems/license/add-license-file.patch b/omnibus/config/patches/rubygems/license/add-license-file.patch deleted file mode 100644 index bcc5e92f5..000000000 --- a/omnibus/config/patches/rubygems/license/add-license-file.patch +++ /dev/null @@ -1,60 +0,0 @@ -diff --git a/LICENSE.txt b/LICENSE.txt -new file mode 100644 -index 0000000..8a0a51d ---- /dev/null -+++ b/LICENSE.txt -@@ -0,0 +1,54 @@ -+RubyGems is copyrighted free software by Chad Fowler, Rich Kilmer, Jim -+Weirich and others. You can redistribute it and/or modify it under -+either the terms of the MIT license (see the file MIT.txt), or the -+conditions below: -+ -+1. You may make and give away verbatim copies of the source form of the -+ software without restriction, provided that you duplicate all of the -+ original copyright notices and associated disclaimers. -+ -+2. You may modify your copy of the software in any way, provided that -+ you do at least ONE of the following: -+ -+ a. place your modifications in the Public Domain or otherwise -+ make them Freely Available, such as by posting said -+ modifications to Usenet or an equivalent medium, or by allowing -+ the author to include your modifications in the software. -+ -+ b. use the modified software only within your corporation or -+ organization. -+ -+ c. give non-standard executables non-standard names, with -+ instructions on where to get the original software distribution. -+ -+ d. make other distribution arrangements with the author. -+ -+3. You may distribute the software in object code or executable -+ form, provided that you do at least ONE of the following: -+ -+ a. distribute the executables and library files of the software, -+ together with instructions (in the manual page or equivalent) -+ on where to get the original distribution. -+ -+ b. accompany the distribution with the machine-readable source of -+ the software. -+ -+ c. give non-standard executables non-standard names, with -+ instructions on where to get the original software distribution. -+ -+ d. make other distribution arrangements with the author. -+ -+4. You may modify and include the part of the software into any other -+ software (possibly commercial). -+ -+5. The scripts and library files supplied as input to or produced as -+ output from the software do not automatically fall under the -+ copyright of the software, but belong to whomever generated them, -+ and may be sold commercially, and may be aggregated with this -+ software. -+ -+6. THIS SOFTWARE IS PROVIDED "AS IS" AND WITHOUT ANY EXPRESS OR -+ IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED -+ WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR -+ PURPOSE. -+ diff --git a/omnibus/config/patches/runit/log-status.patch b/omnibus/config/patches/runit/log-status.patch deleted file mode 100644 index cfdaeee40..000000000 --- a/omnibus/config/patches/runit/log-status.patch +++ /dev/null @@ -1,13 +0,0 @@ -diff --git a/sv.c b/sv.c -index 0125795..b79dc4f 100644 ---- a/sv.c -+++ b/sv.c -@@ -167,7 +167,7 @@ int status(char *unused) { - } - else { - outs("; "); -- if (svstatus_get()) { rc =svstatus_print("log"); outs("\n"); } -+ if (svstatus_get()) { svstatus_print("log"); outs("\n"); } - } - islog =0; - flush(""); diff --git a/omnibus/config/patches/zlib/zlib-windows-relocate.patch b/omnibus/config/patches/zlib/zlib-windows-relocate.patch deleted file mode 100644 index 6d92496e8..000000000 --- a/omnibus/config/patches/zlib/zlib-windows-relocate.patch +++ /dev/null @@ -1,19 +0,0 @@ ---- zlib-1.2.8/win32/Makefile.gcc.orig 2016-02-11 13:46:54.000000000 -0500 -+++ zlib-1.2.8/win32/Makefile.gcc 2016-02-11 13:53:08.000000000 -0500 -@@ -57,6 +57,8 @@ - RC = $(PREFIX)windres - RCFLAGS = --define GCC_WINDRES - -+IMAGE_BASE = 0x63300000 -+ - STRIP = $(PREFIX)strip - - CP = cp -fp -@@ -93,7 +95,7 @@ - $(IMPLIB): $(SHAREDLIB) - - $(SHAREDLIB): win32/zlib.def $(OBJS) $(OBJA) zlibrc.o -- $(CC) -shared -Wl,--out-implib,$(IMPLIB) $(LDFLAGS) \ -+ $(CC) -shared -Wl,--out-implib,$(IMPLIB),--image-base,$(IMAGE_BASE) $(LDFLAGS) \ - -o $@ win32/zlib.def $(OBJS) $(OBJA) zlibrc.o - $(STRIP) $@ diff --git a/omnibus/config/projects/firezone.rb b/omnibus/config/projects/firezone.rb deleted file mode 100644 index d8b550871..000000000 --- a/omnibus/config/projects/firezone.rb +++ /dev/null @@ -1,57 +0,0 @@ -# frozen_string_literal: true - -# Copyright 2021 Firezone -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -# - -name 'firezone' -maintainer 'Firezone' -homepage 'https://firezone.dev' -license 'Apache-2.0' -license_file '../LICENSE' - -description <<~DESC - Open source secure remote access platform. -DESC - -# Defaults to C:/firezone on Windows -# and /opt/firezone on all other platforms -install_dir "#{default_root}/#{name}" - -# Prevent runner tmp dir from filling up -stage_path = '/opt/runner/omnibus-local/stage' -ENV['CI'] && Dir.exist?(stage_path) && staging_dir(stage_path) - -# Use Release Drafter's resolved version -build_version ENV.fetch('VERSION', '0.0.0+git.0.ci') -build_iteration 1 - -# firezone build dependencies/components -dependency 'runit' -dependency 'nginx' -dependency 'elixir' -dependency 'openssl' -dependency 'postgresql' -dependency 'firezone' -dependency 'firezone-ctl' -dependency 'firezone-scripts' -dependency 'firezone-cookbooks' - -# XXX: Ensure all development resources aren't included -exclude '.env' -exclude '.github' -exclude '.vagrant' -exclude '.ci' -exclude '**/.git' -exclude '**/bundler/git' diff --git a/omnibus/config/software/acme.rb b/omnibus/config/software/acme.rb deleted file mode 100644 index a4096ea4c..000000000 --- a/omnibus/config/software/acme.rb +++ /dev/null @@ -1,19 +0,0 @@ -# frozen_string_literal: true - -name 'acme' - -default_version '3.0.4' - -source url: "https://github.com/acmesh-official/acme.sh/archive/refs/tags/#{version}.tar.gz" - -license 'GPL-3.0' - -version('3.0.4') do - source sha256: 'c2855836a6db5766474c860fa54fa2f9f378ab334856b0cf0d07512866b808bb' -end - -relative_path "acme.sh-#{version}" - -build do - copy 'acme.sh', "#{install_dir}/embedded/bin" -end diff --git a/omnibus/config/software/autoconf.rb b/omnibus/config/software/autoconf.rb deleted file mode 100644 index 52affc819..000000000 --- a/omnibus/config/software/autoconf.rb +++ /dev/null @@ -1,47 +0,0 @@ -# frozen_string_literal: true - -# -# Copyright:: Chef Software, Inc. -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -# -# expeditor/ignore: deprecated 2021-04 - -name 'autoconf' -default_version '2.71' - -license 'GPL-3.0' -license_file 'COPYING' -license_file 'COPYING.EXCEPTION' -skip_transitive_dependency_licensing true - -dependency 'm4' - -version('2.69') { source sha256: '954bd69b391edc12d6a4a51a2dd1476543da5c6bbf05a95b59dc0dd6fd4c2969' } -version('2.71') { source sha256: '431075ad0bf529ef13cb41e9042c542381103e80015686222b8a9d4abef42a1c' } - -source url: "https://mirrors.kernel.org/gnu/autoconf/autoconf-#{version}.tar.gz" - -relative_path "autoconf-#{version}" - -build do - env = with_standard_compiler_flags(with_embedded_path) - - env['M4'] = "#{install_dir}/embedded/bin/m4" if solaris2? - - command './configure' \ - " --prefix=#{install_dir}/embedded", env: env - - make "-j #{workers}", env: env - make "-j #{workers} install", env: env -end diff --git a/omnibus/config/software/automake.rb b/omnibus/config/software/automake.rb deleted file mode 100644 index 3f1866875..000000000 --- a/omnibus/config/software/automake.rb +++ /dev/null @@ -1,52 +0,0 @@ -# frozen_string_literal: true - -# -# Copyright 2012-2014 Chef Software, Inc. -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -# -# expeditor/ignore: deprecated 2021-04 - -name 'automake' -default_version '1.16.4' - -dependency 'autoconf' -dependency 'perl-thread-queue' - -license 'GPL-2.0' -license_file 'COPYING' -skip_transitive_dependency_licensing true - -version('1.16.4') { source sha256: '8a0f0be7aaae2efa3a68482af28e5872d8830b9813a6a932a2571eac63ca1794' } -version('1.16') { source sha256: '80da43bb5665596ee389e6d8b64b4f122ea4b92a685b1dbd813cd1f0e0c2d83f' } -version('1.15') { source sha256: '7946e945a96e28152ba5a6beb0625ca715c6e32ac55f2e353ef54def0c8ed924' } -version('1.11.2') { source sha256: 'c339e3871d6595620760725da61de02cf1c293af8a05b14592d6587ac39ce546' } - -source url: "https://mirrors.kernel.org/gnu/automake/automake-#{version}.tar.gz" - -relative_path "automake-#{version}" - -build do - env = with_standard_compiler_flags(with_embedded_path) - - if version == '1.15' - command './bootstrap.sh', env: env - else - command './bootstrap', env: env - end - command './configure' \ - " --prefix=#{install_dir}/embedded", env: env - - make "-j #{workers}", env: env - make "-j #{workers} install", env: env -end diff --git a/omnibus/config/software/bison.rb b/omnibus/config/software/bison.rb deleted file mode 100644 index 9bdaf93af..000000000 --- a/omnibus/config/software/bison.rb +++ /dev/null @@ -1,41 +0,0 @@ -# frozen_string_literal: true - -# Copyright:: Firezone -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -# -# expeditor/ignore: deprecated 2021-04 -name 'bison' - -dependency 'readline' -dependency 'config_guess' - -license 'GPL-3.0' -license_file 'COPYING' -skip_transitive_dependency_licensing true -default_version '3.7' -source url: "http://mirrors.kernel.org/gnu/bison/bison-#{version}.tar.gz" -version('3.7') do - source sha256: '492ad61202de893ca21a99b621d63fa5389da58804ad79d3f226b8d04b803998' -end -relative_path "bison-#{version}" - -build do - env = with_standard_compiler_flags(with_embedded_path) - - update_config_guess - - command "./configure --prefix=#{install_dir}/embedded", env: env - make "-j #{workers}", env: env - make "-j #{workers} install", env: env -end diff --git a/omnibus/config/software/bzip2.rb b/omnibus/config/software/bzip2.rb deleted file mode 100644 index 2f02f3b0f..000000000 --- a/omnibus/config/software/bzip2.rb +++ /dev/null @@ -1,57 +0,0 @@ -# frozen_string_literal: true - -# -# Copyright 2013-2018 Chef Software, Inc. -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -# -# Install bzip2 and its shared library, libbz2.so -# This library object is required for building Python with the bz2 module, -# and should be picked up automatically when building Python. - -name 'bzip2' -default_version '1.0.8' - -license 'BSD-2-Clause' -license_file 'LICENSE' -skip_transitive_dependency_licensing true - -dependency 'zlib' -dependency 'openssl' - -# version_list: url=https://sourceware.org/pub/bzip2/ filter=*.tar.gz -version('1.0.8') { source sha256: 'ab5a03176ee106d3f0fa90e381da478ddae405918153cca248e682cd0c4a2269' } - -source url: "https://fossies.org/linux/misc/#{name}-#{version}.tar.gz" - -relative_path "#{name}-#{version}" - -build do - env = with_standard_compiler_flags(with_embedded_path) - - # Avoid warning where .rodata cannot be used when making a shared object - env['CFLAGS'] << ' -fPIC' unless aix? - - # The list of arguments to pass to make - args = "PREFIX='#{install_dir}/embedded' VERSION='#{version}'" - args << " CFLAGS='-qpic=small -qpic=large -O2 -g -D_ALL_SOURCE -D_LARGE_FILES'" if aix? - - patch source: 'makefile_take_env_vars.patch', plevel: 1, env: env - patch source: 'makefile_no_bins.patch', plevel: 1, env: env # removes various binaries we don't want to ship - patch source: 'soname_install_dir.patch', env: env if mac_os_x? - patch source: 'aix_makefile.patch', env: env if aix? - - make "#{args} -j #{workers}", env: env - make "#{args} -j #{workers} -f Makefile-libbz2_so", env: env - make "#{args} -j #{workers} install", env: env -end diff --git a/omnibus/config/software/cacerts.rb b/omnibus/config/software/cacerts.rb deleted file mode 100644 index 5ceff6729..000000000 --- a/omnibus/config/software/cacerts.rb +++ /dev/null @@ -1,52 +0,0 @@ -# frozen_string_literal: true - -# -# Copyright:: Chef Software, Inc. -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -# - -name 'cacerts' - -license 'MPL-2.0' -license_file 'https://www.mozilla.org/media/MPL/2.0/index.815ca599c9df.txt' -skip_transitive_dependency_licensing true - -default_version '2021-01-19' - -source url: "https://curl.haxx.se/ca/cacert-#{version}.pem" - -# versions_list: https://curl.se/docs/caextract.html -version('2021-01-19') { source sha256: 'e010c0c071a2c79a76aa3c289dc7e4ac4ed38492bfda06d766a80b707ebd2f29' } -version('2020-12-08') { source sha256: '313d562594ebd07846ad6b840dd18993f22e0f8b3f275d9aacfae118f4f00fb7' } -version('2020-10-14') { source sha256: 'bb28d145ed1a4ee67253d8ddb11268069c9dafe3db25a9eee654974c4e43eee5' } -version('2020-07-22') { source sha256: '2782f0f8e89c786f40240fc1916677be660fb8d8e25dede50c9f6f7b0c2c2178' } -version('2020-06-24') { source sha256: '726889705b00f736200ed7999f7a50021b8735d53228d679c4e6665aa3b44987' } - -relative_path "cacerts-#{version}" - -build do - mkdir "#{install_dir}/embedded/ssl/certs" - - copy "#{project_dir}/cacert*.pem", "#{install_dir}/embedded/ssl/certs/cacert.pem" - copy "#{project_dir}/cacert*.pem", "#{install_dir}/embedded/ssl/cert.pem" if windows? - - # Windows does not support symlinks - unless windows? - link 'certs/cacert.pem', "#{install_dir}/embedded/ssl/cert.pem", - unchecked: true, - force: true - - block { File.chmod(0o644, "#{install_dir}/embedded/ssl/certs/cacert.pem") } - end -end diff --git a/omnibus/config/software/config_guess.rb b/omnibus/config/software/config_guess.rb deleted file mode 100644 index b3f6d72e3..000000000 --- a/omnibus/config/software/config_guess.rb +++ /dev/null @@ -1,39 +0,0 @@ -# frozen_string_literal: true - -# -# Copyright 2015 Chef Software, Inc. -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -# -# expeditor/ignore: no version pinning - -name 'config_guess' -default_version 'master' - -# Use our github mirror of the savannah repository -source git: 'https://github.com/chef/config-mirror.git' - -# http://savannah.gnu.org/projects/config -license 'GPL-3.0 (with exception)' -license_file 'config.guess' -license_file 'config.sub' -skip_transitive_dependency_licensing true - -relative_path "config_guess-#{version}" - -build do - mkdir "#{install_dir}/embedded/lib/config_guess" - - copy "#{project_dir}/config.guess", "#{install_dir}/embedded/lib/config_guess/config.guess" - copy "#{project_dir}/config.sub", "#{install_dir}/embedded/lib/config_guess/config.sub" -end diff --git a/omnibus/config/software/elixir.rb b/omnibus/config/software/elixir.rb deleted file mode 100644 index ae74dfb29..000000000 --- a/omnibus/config/software/elixir.rb +++ /dev/null @@ -1,46 +0,0 @@ -# frozen_string_literal: true - -# Copyright 2017 Chef Software, Inc. -# Copyright 2021 Firezone -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -# -# expeditor/ignore: deprecated 2021-04 - -name 'elixir' -default_version '1.14.0' - -license 'Apache-2.0' -license_file 'LICENSE' - -dependency 'erlang' - -version('1.4.2') { source sha256: 'cb4e2ec4d68b3c8b800179b7ae5779e2999aa3375f74bd188d7d6703497f553f' } -version('1.12.2') { source sha256: '701006d1279225fc42f15c8d3f39906db127ddcc95373d34d8d160993356b15c' } -version('1.12.3') { source sha256: 'c5affa97defafa1fd89c81656464d61da8f76ccfec2ea80c8a528decd5cb04ad' } -version('1.13.1') { source sha256: 'deaba8156b11777adfa28e54e76ddf49ab1a0132cca54c41d9d7648e800edcc8' } -version('1.13.2') { source sha256: '03afed42dccf4347c4d3ae2b905134093a3ba2245d0d3098d75009a1d659ed1a' } -version('1.13.4') { source sha256: '95daf2dd3052e6ca7d4d849457eaaba09de52d65ca38d6933c65bc1cdf6b8579' } -version('1.14.0') { source sha256: 'ac129e266a1e04cdc389551843ec3dbdf36086bb2174d3d7e7936e820735003b' } - -source url: "https://github.com/elixir-lang/elixir/archive/v#{version}.tar.gz" -relative_path "elixir-#{version}" - -build do - env = with_standard_compiler_flags( - 'PATH' => "/opt/runner/local/bin:#{with_embedded_path['PATH']}" - ) - - make "-j #{workers}", env: env - make "-j #{workers} install PREFIX=/opt/runner/local", env: env -end diff --git a/omnibus/config/software/erlang.rb b/omnibus/config/software/erlang.rb deleted file mode 100644 index a1f8ab405..000000000 --- a/omnibus/config/software/erlang.rb +++ /dev/null @@ -1,156 +0,0 @@ -# frozen_string_literal: true - -# -# Copyright:: Chef Software, Inc. -# Copyright:: Firezone -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -# - -name 'erlang' - -default_version '25.1' - -license 'Apache-2.0' -license_file 'LICENSE.txt' -skip_transitive_dependency_licensing true - -dependency 'gawk' -dependency 'automake' -dependency 'autoconf' -dependency 'zlib' -dependency 'openssl' -dependency 'config_guess' - -# grab from github so we can get patch releases if we need to -source url: "https://github.com/erlang/otp/archive/OTP-#{version}.tar.gz" -relative_path "otp-OTP-#{version}" - -# versions_list: https://github.com/erlang/otp/tags filter=*.tar.gz -version('25.1') { source sha256: 'e00b2e02350688ee4ac83c41ec25c210774fe73b7f806860c46b185457ae135e' } -version('25.0.4') { source sha256: '05878cb51a64b33c86836b12a21903075c300409b609ad5e941ddb0feb8c2120' } -version('25.0.3') { source sha256: 'e8eca69b6bdaac9cc8f3e3177dd2913920513495ee83bdecf73af546768febd6' } -version('25.0.2') { source sha256: 'f78764c6fd504f7b264c47e469c0fcb86a01c92344dc9d625dfd42f6c3ed8224' } -version('25.0.1') { source sha256: '4426bdf717c9f359f592fceb5dc29b9cab152010cd258475730de4582de42bff' } -version('25.0') { source sha256: '5988e3bca208486494446e885ca2149fe487ee115cbc3770535fd22a795af5d2' } -version('24.3.4') { source sha256: 'e59bedbb871af52244ca5284fd0a572d52128abd4decf4347fe2aef047b65c58' } -version('24.2.1') { source sha256: '2854318d12d727fc508e8fd5fe6921c0cbc7727d1183ad8f6f808585496e42d6' } -version('24.2') { source sha256: '0b9c9ba7d8b40f6c77d529e07561b10f0914d2bfe9023294d7eda85b62936792' } -version('24.1.4') { source sha256: 'aa31ba689740dc446dfa5bb256474df5fb5e5459b981b4d2155afa91010ca66a' } -version('24.0.6') { source sha256: 'a60a7d776a4573e2018d6fad6df957e3911ecbce5f11497a8ec537f613aca0a1' } -version('24.0.5') { source sha256: 'dd189cf94bf86c610a66f5d9f1a49b8d95a7ce1a7534d216e97e8fade271e624' } -version('23.3.3') { source sha256: '839d74e71a457295d95b8674f1848a5d7d9c4c274a041ef8026d035da88858ae' } -version('23.3.2') { source sha256: '02443dd42023d0eb73f73dc05f4d3ded7bc4ab59d348041a37a045ba1581b48b' } -version('22.2') { source sha256: '232c37a502c7e491a9cbf86acb7af64fbc1a793fcbcbd0093cb029cf1c3830a7' } -version('22.1.8') { source sha256: '7302be70cee2c33689bf2c2a3e7cfee597415d0fb3e4e71bd3e86bd1eff9cfdc' } -version('21.3.8.11') { source sha256: 'aab77124285820608cd7a90f6b882e42bb5739283e10a8593d7f5bce9b30b16a' } -version('21.1') { source sha256: '7212f895ae317fa7a086fa2946070de5b910df5d41263e357d44b0f1f410af0f' } -version('20.3.8.9') { source sha256: '897dd8b66c901bfbce09ed64e0245256aca9e6e9bdf78c36954b9b7117192519' } -version('20.0') { source sha256: '22710927ad2e48a0964997bf5becb24abb1f4fed86f5f05af22a9e1df636b787' } -version('19.3.6.11') { source sha256: 'c857ea6d2c901bfb633d9ceeb5e05332475357f185dd5112b7b6e4db80072827' } -version('18.3.4.9') { source sha256: '25ef8ba3824cb726c4830abf32c2a2967925b1e33a8e8851dba596e933e2689a' } -version('18.3') { source sha256: 'a6d08eb7df06e749ccaf3049b33ceae617a3c466c6a640ee8d248c2372d48f4e' } -version('18.2') { source sha256: '3944ce41d13fbef1e1e80d7335b2167849e8566581513d5d9226cd211d3d58f9' } -version('18.1') { source sha256: '6b956dda690d3f3bf244249e8d422dd606231cc7229675bf5e34b5ba2ae83e9b' } - -# rubocop:disable Metrics/BlockLength -build do - # Deprecated - # if version.satisfies?('>= 18.3') - # # Don't listen on 127.0.0.1/::1 implicitly whenever ERL_EPMD_ADDRESS is given - # patch source: 'epmd-require-explicitly-adding-loopback-address.patch', plevel: 1 - # end - - env = with_standard_compiler_flags(with_embedded_path).merge( - 'CFLAGS' => "-O2 -g -L#{install_dir}/embedded/lib -I#{install_dir}/embedded/erlang/include", - 'LDFLAGS' => "-Wl,-rpath #{install_dir}/embedded/lib -L#{install_dir}/embedded/lib -I#{install_dir}/embedded/er"\ - 'lang/include' - ) - env.delete('CPPFLAGS') - - # The TYPE env var sets the type of emulator you want - # We want the default so we give TYPE and empty value - # in case it was set by CI. - env['TYPE'] = '' - - update_config_guess(target: 'erts/autoconf') - update_config_guess(target: 'lib/common_test/priv/auxdir') - update_config_guess(target: 'lib/erl_interface/src/auxdir') - update_config_guess(target: 'lib/wx/autoconf') - - if version.satisfies?('>= 19.0') - update_config_guess(target: 'lib/common_test/test_server/src') - else - update_config_guess(target: 'lib/test_server/src') - end - - # Setup the erlang include dir - mkdir "#{install_dir}/embedded/erlang/include" - - # At this time, erlang does not expose a way to specify the path(s) to these - # libraries, but it looks in its local +include+ directory as part of the - # search, so we will symlink them here so they are picked up. - # - # In future releases of erlang, someone should check if these flags (or - # environment variables) are avaiable to remove this ugly hack. - %w[openssl zlib.h zconf.h].each do |name| - link "#{install_dir}/embedded/include/#{name}", "#{install_dir}/embedded/erlang/include/#{name}" - end - - # Note 2017-02-28 sr: HiPE doesn't compile with OTP 18.3 on ppc64le (https://bugs.erlang.org/browse/ERL-369) - # Compiling fails when linking beam.smp, with - # powerpc64le-linux-gnu/libutil.so: error adding symbols: File in wrong format - # - # We've been having issues with ppc64le and hipe before, too: - # https://github.com/chef/chef-server/commit/4fa25ed695acaf819b11f71c6db1aab5c8adcaee - # - # It's trying to compile using a linker script for ppc64, it seems: - # https://github.com/erlang/otp/blob/c1ea854fac3d8ed14/erts/emulator/hipe/elf64ppc.x - # Probably introduced with https://github.com/erlang/otp/commit/37d63e9b8a0a96 - # See also https://sourceware.org/ml/binutils/2015-05/msg00148.html - hipe = ppc64le? ? 'disable' : 'enable' - - unless File.exist?('./configure') - # Building from github source requires this step - command './otp_build autoconf' - end - # NOTE: et, debugger and observer applications require wx to - # build. The tarballs from the downloads site has prebuilt the beam - # files, so we were able to get away without disabling them and - # still build. When building from raw source we must disable them - # explicitly. - wx = 'without' - - command './configure' \ - ' --prefix=/opt/runner/local' \ - ' --enable-threads' \ - ' --enable-smp-support' \ - ' --enable-kernel-poll' \ - ' --enable-dynamic-ssl-lib' \ - ' --enable-shared-zlib' \ - ' --enable-fips' \ - " --#{hipe}-hipe" \ - " --#{wx}-wx" \ - " --#{wx}-et" \ - " --#{wx}-debugger" \ - " --#{wx}-observer" \ - ' --without-termcap' \ - ' --without-megaco' \ - ' --without-javac' \ - " --with-ssl=#{install_dir}/embedded" \ - ' --disable-debug', env: env - - make "-j #{workers}", env: env - make "-j #{workers} install", env: env -end -# rubocop:enable Metrics/BlockLength diff --git a/omnibus/config/software/firezone-cookbooks.rb b/omnibus/config/software/firezone-cookbooks.rb deleted file mode 100644 index 8d549ac30..000000000 --- a/omnibus/config/software/firezone-cookbooks.rb +++ /dev/null @@ -1,70 +0,0 @@ -# rubocop:disable Naming/FileName -# frozen_string_literal: true - -# -# Copyright 2014 Chef Software, Inc. -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -# - -name 'firezone-cookbooks' -license :project_license - -source path: 'cookbooks/firezone' - -# rubocop:disable Metrics/BlockLength -build do - cookbooks_path = "#{install_dir}/embedded/cookbooks" - env = with_standard_compiler_flags(with_embedded_path) - - command "berks vendor #{cookbooks_path}", env: env - - block do - all_the_gem_deps = {} - Dir.glob("#{cookbooks_path}/**/metadata.json").each do |metadata| - cookbook_name = File.basename(File.dirname(metadata)) - metadata_json = FFI_Yajl::Parser.parse(File.read(metadata)) - gem_deps = metadata_json.fetch('gems', []) - all_the_gem_deps[cookbook_name] = gem_deps unless gem_deps.empty? - end - - unless all_the_gem_deps.empty? - raise Omnibus::Error, 'Nope. Gem dependencies found in the following '\ - 'cookbooks used during ctl-reconfigure. This will break airgapped '\ - "installs.\n#{all_the_gem_deps}" - end - end - - block do - File.open("#{cookbooks_path}/dna.json", 'w') do |file| - file.write FFI_Yajl::Encoder.encode(run_list: ['recipe[firezone::default]']) - end - - File.open("#{cookbooks_path}/show-config.json", 'w') do |file| - file.write FFI_Yajl::Encoder.encode( - run_list: ['recipe[firezone::show_config]'] - ) - end - - File.open("#{cookbooks_path}/solo.rb", 'w') do |file| - file.write <<~SOLO - cookbook_path "#{cookbooks_path}" - cache_path "/var/opt/firezone/cache" - verbose_logging true - ssl_verify_mode :verify_peer - SOLO - end - end -end -# rubocop:enable Metrics/BlockLength -# rubocop:enable Naming/FileName diff --git a/omnibus/config/software/firezone-ctl.rb b/omnibus/config/software/firezone-ctl.rb deleted file mode 100644 index 79f075eb9..000000000 --- a/omnibus/config/software/firezone-ctl.rb +++ /dev/null @@ -1,48 +0,0 @@ -# rubocop:disable Naming/FileName -# frozen_string_literal: true - -# -# Copyright 2014 Chef Software, Inc. -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -# - -name 'firezone-ctl' -license :project_license - -dependency 'omnibus-ctl' -dependency 'runit' - -source path: 'cookbooks/firezone' - -build do - env = with_standard_compiler_flags(with_embedded_path) - - bundle 'install --binstubs --without test', env: env - - mkdir "#{install_dir}/bin" - - block do - erb source: 'firezone-ctl.erb', - dest: "#{install_dir}/bin/firezone-ctl", - mode: 0o755, - vars: { - embedded_bin: "#{install_dir}/embedded/bin", - embedded_service: "#{install_dir}/embedded/service" - } - end - - # additional omnibus-ctl commands - sync "#{project_dir}/files/default/ctl-commands", "#{install_dir}/embedded/service/omnibus-ctl/" -end -# rubocop:enable Naming/FileName diff --git a/omnibus/config/software/firezone-scripts.rb b/omnibus/config/software/firezone-scripts.rb deleted file mode 100644 index e09b992c1..000000000 --- a/omnibus/config/software/firezone-scripts.rb +++ /dev/null @@ -1,34 +0,0 @@ -# rubocop:disable Naming/FileName -# frozen_string_literal: true - -# -# Copyright:: Copyright (c) 2015 GitLab B.V. -# Copyright:: Copyright (c) 2021 Firezone -# License:: Apache License, Version 2.0 -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -# - -name 'firezone-scripts' - -license 'Apache-2.0' -license_file File.expand_path('LICENSE', Omnibus::Config.project_root) - -skip_transitive_dependency_licensing true - -source path: File.expand_path('files/firezone-scripts', Omnibus::Config.project_root) - -build do - copy '*', "#{install_dir}/embedded/bin/" -end -# rubocop:enable Naming/FileName diff --git a/omnibus/config/software/firezone.rb b/omnibus/config/software/firezone.rb deleted file mode 100644 index ee86293d4..000000000 --- a/omnibus/config/software/firezone.rb +++ /dev/null @@ -1,69 +0,0 @@ -# frozen_string_literal: true - -# Copyright 2021 Firezone -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -# - -name 'firezone' -description 'the steps required to compile the firezone elixir application' -default_version '1.0.0' - -dependency 'postgresql' -dependency 'elixir' -dependency 'nftables' if linux? -dependency 'ruby' - -version('1.0.0') do - source path: File.expand_path('../', Omnibus::Config.project_root), - options: { exclude: [ - '.env', - '.git', - '.ci', - 'docs', - 'doc', - 'priv', - 'scripts', - 'tmp', - '.vagrant', - '.github', - '_build', - 'deps', - 'omnibus', - 'apps/fz_http/assets/node_modules', - 'apps/fz_http/priv/cert' - ] } -end - -license :project_license -skip_transitive_dependency_licensing true - -build do - env = with_standard_compiler_flags( - 'PATH' => "/opt/runner/local/bin:#{with_embedded_path['PATH']}" - ).merge( - 'MIX_ENV' => 'prod', - 'VERSION' => ENV.fetch('VERSION', '0.0.0+git.0.ci') - ) - - command 'mix local.hex --force', env: env - command 'mix local.rebar --force', env: env - command 'mix deps.get --only prod', env: env - command 'mix deps.compile --only prod', env: env - command 'cd apps/fz_http/assets && yarn install --frozen-lockfile', env: env - command 'cd apps/fz_http/assets && yarn deploy', env: env - command 'cd apps/fz_http && mix phx.digest', env: env - command 'mix release', env: env - - sync '_build/prod/rel/firezone', "#{install_dir}/embedded/service/firezone" -end diff --git a/omnibus/config/software/flex.rb b/omnibus/config/software/flex.rb deleted file mode 100644 index 4ca970247..000000000 --- a/omnibus/config/software/flex.rb +++ /dev/null @@ -1,43 +0,0 @@ -# frozen_string_literal: true - -# Copyright:: Firezone -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -name 'flex' -license_file 'COPYING' -skip_transitive_dependency_licensing true -default_version '2.6.4' -source url: "https://github.com/westes/flex/releases/download/v#{version}/flex-#{version}.tar.gz" -version('2.6.4') do - source sha256: 'e87aae032bf07c26f85ac0ed3250998c37621d95f8bd748b31f15b33c45ee995' -end -relative_path "#{name}-#{version}" - -dependency 'bison' -dependency 'm4' -dependency 'gettext' -dependency 'libtool' -dependency 'autoconf' -dependency 'automake' - -build do - env = with_standard_compiler_flags(with_embedded_path) - - # Fixes https://github.com/spack/spack/issues/8152 - env['CFLAGS'] << ' -D_GNU_SOURCE' if debian? - - command './autogen.sh', env: env - command "./configure --prefix=#{install_dir}/embedded", env: env - make "-j #{workers}", env: env - make "-j #{workers} install", env: env -end diff --git a/omnibus/config/software/gawk.rb b/omnibus/config/software/gawk.rb deleted file mode 100644 index d76170502..000000000 --- a/omnibus/config/software/gawk.rb +++ /dev/null @@ -1,40 +0,0 @@ -# frozen_string_literal: true - -# Copyright:: Firezone, Inc. -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -name 'gawk' - -default_version '5.1.0' - -version('5.1.0') { source sha256: '03a0360edcd84bec156fe211bbc4fc8c78790973ce4e8b990a11d778d40b1a26' } - -source url: "https://mirrors.kernel.org/gnu/gawk/gawk-#{version}.tar.gz" - -dependency 'readline' -dependency 'config_guess' - -relative_path "gawk-#{version}" - -build do - env = with_standard_compiler_flags(with_embedded_path) - update_config_guess - configure_command = ['./configure', - '--disable-mpfr', - "--prefix=#{install_dir}/embedded"] - - command configure_command.join(' '), env: env - make "-j #{workers}", env: env - make "-j #{workers} install", env: env -end diff --git a/omnibus/config/software/gettext.rb b/omnibus/config/software/gettext.rb deleted file mode 100644 index 277098c1a..000000000 --- a/omnibus/config/software/gettext.rb +++ /dev/null @@ -1,56 +0,0 @@ -# frozen_string_literal: true - -# Copyright:: Firezone -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -name 'gettext' -license 'GPL-3.0' -license_file 'COPYING' - -default_version '0.21' - -dependency 'm4' -dependency 'autoconf' -dependency 'automake' -dependency 'bison' -dependency 'perl' -dependency 'libiconv' -dependency 'ncurses' -dependency 'bzip2' -dependency 'zlib' -dependency 'libxml2' -dependency 'liblzma' -dependency 'icu' -dependency 'pkg-config' - -source url: "https://mirrors.kernel.org/gnu/gettext/gettext-#{version}.tar.gz" -version('0.21') do - source sha256: 'c77d0da3102aec9c07f43671e60611ebff89a996ef159497ce8e59d075786b12' -end - -relative_path "#{name}-#{version}" - -build do - env = with_standard_compiler_flags(with_embedded_path) - configure_command = [ - './configure', - # Enabling OpenMP requires libgomp, which requires building gcc which is very slow. - '--disable-openmp', - "--prefix=#{install_dir}/embedded" - ] - - command configure_command, env: env - make "-j #{workers}", env: env - make "-j #{workers} install", env: env -end diff --git a/omnibus/config/software/gmp.rb b/omnibus/config/software/gmp.rb deleted file mode 100644 index 357faa45b..000000000 --- a/omnibus/config/software/gmp.rb +++ /dev/null @@ -1,48 +0,0 @@ -# frozen_string_literal: true - -# -# Copyright 2014 Chef Software, Inc. -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -# - -name 'gmp' -default_version '6.2.1' - -# version_list: url=https://ftp.gnu.org/gnu/gmp/ filter=*.tar.bz2 - -version('6.2.1') { source sha256: 'eae9326beb4158c386e39a356818031bd28f3124cf915f8c5b1dc4c7a36b4d7c' } -version('6.1.0') { source sha256: '498449a994efeba527885c10405993427995d3f86b8768d8cdf8d9dd7c6b73e8' } -version('6.0.0a') { source sha256: '7f8e9a804b9c6d07164cf754207be838ece1219425d64e28cfa3e70d5c759aaf' } - -source url: "https://mirrors.kernel.org/gnu/gmp/gmp-#{version}.tar.bz2" - -if version == '6.0.0a' - # version 6.0.0a expands to 6.0.0 - relative_path 'gmp-6.0.0' -else - relative_path "gmp-#{version}" -end - -build do - env = with_standard_compiler_flags(with_embedded_path) - - env['ABI'] = '32' if solaris2? - - configure_command = ['./configure', - "--prefix=#{install_dir}/embedded"] - - command configure_command.join(' '), env: env - make "-j #{workers}", env: env - make "-j #{workers} install", env: env -end diff --git a/omnibus/config/software/icu.rb b/omnibus/config/software/icu.rb deleted file mode 100644 index daee77ad5..000000000 --- a/omnibus/config/software/icu.rb +++ /dev/null @@ -1,29 +0,0 @@ -# frozen_string_literal: true - -name 'icu' -license_file 'LICENSE' -skip_transitive_dependency_licensing true -default_version '71.1' - -source url: "https://github.com/unicode-org/icu/releases/download/release-#{version.gsub('.', - '-')}/icu4c-#{version.gsub( - '.', '_' - )}-src.tgz" - -version('71.1') do - source sha256: '67a7e6e51f61faf1306b6935333e13b2c48abd8da6d2f46ce6adca24b1e21ebf' -end -version('69.1') do - source sha256: '4cba7b7acd1d3c42c44bb0c14be6637098c7faf2b330ce876bc5f3b915d09745' -end - -relative_path 'icu/source' - -build do - env = with_standard_compiler_flags(with_embedded_path) - - command "./configure --prefix=#{install_dir}/embedded", env: env - - make "-j #{workers}", env: env - make "-j #{workers} install", env: env -end diff --git a/omnibus/config/software/libedit.rb b/omnibus/config/software/libedit.rb deleted file mode 100644 index 6def2bffd..000000000 --- a/omnibus/config/software/libedit.rb +++ /dev/null @@ -1,68 +0,0 @@ -# frozen_string_literal: true - -# Copyright 2012-2014 Chef Software, Inc. -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -# - -name 'libedit' -default_version '20210910-3.1' - -license 'BSD-3-Clause' -license_file 'COPYING' -skip_transitive_dependency_licensing true - -dependency 'ncurses' -dependency 'config_guess' - -# version_list: url=http://thrysoee.dk/editline/ filter=*.tar.gz - -version('20210910-3.1') { source sha256: '6792a6a992050762edcca28ff3318cdb7de37dccf7bc30db59fcd7017eed13c5' } -version('20210419-3.1') { source sha256: '571ebe44b74860823e24a08cf04086ff104fd7dfa1020abf26c52543134f5602' } -version('20150325-3.1') { source sha256: 'c88a5e4af83c5f40dda8455886ac98923a9c33125699742603a88a0253fcc8c5' } -version('20141030-3.1') { source sha256: '9701e16570fb8f7fa407b506986652221b701a9dd61defc05bb7d1c61cdf5a40' } -version('20130712-3.1') { source sha256: '5d9b1a9dd66f1fe28bbd98e4d8ed1a22d8da0d08d902407dcc4a0702c8d88a37' } -version('20120601-3.0') { source sha256: '51f0f4b4a97b7ebab26e7b5c2564c47628cdb3042fd8ba8d0605c719d2541918' } - -source url: "http://www.thrysoee.dk/editline/libedit-#{version}.tar.gz" - -if version == '20141030-3.1' - # released tar file has name discrepency in folder name for this version - relative_path 'libedit-20141029-3.1' -else - relative_path "libedit-#{version}" -end - -build do - env = with_standard_compiler_flags(with_embedded_path) - - # The patch is from the FreeBSD ports tree and is for GCC compatibility. - # http://svnweb.freebsd.org/ports/head/devel/libedit/files/patch-vi.c?annotate=300896 - patch source: 'freebsd-vi-fix.patch', env: env if version.to_i < 20_150_325 && (freebsd? || openbsd?) - - if openbsd? - patch source: 'openbsd-weak-alias-fix.patch', plevel: 1, env: env - elsif aix? - # this forces us to build correctly, in the event that the system locale - # is non-standard. - env['LC_ALL'] = 'en_US' - end - - update_config_guess - - command './configure' \ - " --prefix=#{install_dir}/embedded", env: env - - make "-j #{workers}", env: env - make "-j #{workers} install", env: env -end diff --git a/omnibus/config/software/libffi.rb b/omnibus/config/software/libffi.rb deleted file mode 100644 index 822969ee4..000000000 --- a/omnibus/config/software/libffi.rb +++ /dev/null @@ -1,64 +0,0 @@ -# frozen_string_literal: true - -# -# Copyright:: Chef Software, Inc. -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -# - -name 'libffi' -default_version '3.4.2' - -license 'MIT' -license_file 'LICENSE' -skip_transitive_dependency_licensing true - -# version_list: url=ftp://sourceware.org/pub/libffi/ filter=*.tar.gz - -version('3.2.1') { source sha256: 'd06ebb8e1d9a22d19e38d63fdb83954253f39bedc5d46232a05645685722ca37' } -version('3.3') { source sha256: '72fba7922703ddfa7a028d513ac15a85c8d54c8d67f55fa5a4802885dc652056' } -version('3.4.2') { source sha256: '540fb721619a6aba3bdeef7d940d8e9e0e6d2c193595bc243241b77ff9e93620' } - -source url: "https://github.com/libffi/libffi/releases/download/v#{version}/libffi-#{version}.tar.gz" -relative_path "libffi-#{version}" - -build do - env = with_standard_compiler_flags(with_embedded_path) - - env['INSTALL'] = '/opt/freeware/bin/install' if aix? - - # disable option checking as disable-docs is 3.3+ only - configure_command = ['--disable-option-checking', - '--disable-docs'] - - patch source: 'libffi-3.3-arm64.patch', plevel: 1, env: env if version == '3.3' && mac_os_x? && arm? - - # AIX's old version of patch doesn't like the patch here - unless aix? - # disable multi-os-directory via configure flag (don't use /lib64) - # Works on all platforms, and is compatible on 32bit platforms as well - configure_command << '--disable-multi-os-directory' - - # add the --disable-multi-os-directory flag to 3.2.1 - patch source: 'libffi-3.2.1-disable-multi-os-directory.patch', plevel: 1, env: env if version == '3.2.1' - end - - configure(*configure_command, env: env) - - make "-j #{workers}", env: env - make "-j #{workers} install", env: env - - # libffi's default install location of header files is awful... - mkdir "#{install_dir}/embedded/include" - copy "#{install_dir}/embedded/lib/libffi-#{version}/include/*", "#{install_dir}/embedded/include/" -end diff --git a/omnibus/config/software/libiconv.rb b/omnibus/config/software/libiconv.rb deleted file mode 100644 index 27a9df8bc..000000000 --- a/omnibus/config/software/libiconv.rb +++ /dev/null @@ -1,55 +0,0 @@ -# frozen_string_literal: true - -# -# Copyright:: Chef Software, Inc. -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -# - -# CAUTION - although its not used, external libraries such as nokogiri may pick up an optional dep on -# libiconv such that removal of libiconv will break those libraries on upgrade. With an better story around -# external gem handling when chef-client is upgraded libconv could be dropped. -name 'libiconv' -default_version '1.16' - -license 'LGPL-2.1' -license_file 'COPYING.LIB' -skip_transitive_dependency_licensing true - -dependency 'config_guess' - -# versions_list: https://ftp.gnu.org/pub/gnu/libiconv/ filter=*.tar.gz -version('1.15') { source sha256: 'ccf536620a45458d26ba83887a983b96827001e92a13847b45e4925cc8913178' } -version('1.16') { source sha256: 'e6a1b1b589654277ee790cce3734f07876ac4ccfaecbee8afa0b649cf529cc04' } - -source url: "https://mirrors.kernel.org/gnu/libiconv/libiconv-#{version}.tar.gz" - -relative_path "libiconv-#{version}" - -build do - env = with_standard_compiler_flags(with_embedded_path) - - # freebsd 10 needs to be build PIC - env['CFLAGS'] << ' -fPIC' if freebsd? - - update_config_guess(target: 'build-aux') - update_config_guess(target: 'libcharset/build-aux') - - configure(env: env) - - pmake = "-j #{workers}" - make pmake.to_s, env: env - make "#{pmake} install-lib" \ - " libdir=#{install_dir}/embedded/lib" \ - " includedir=#{install_dir}/embedded/include", env: env -end diff --git a/omnibus/config/software/liblzma.rb b/omnibus/config/software/liblzma.rb deleted file mode 100644 index f7e36571f..000000000 --- a/omnibus/config/software/liblzma.rb +++ /dev/null @@ -1,60 +0,0 @@ -# frozen_string_literal: true - -# -# Copyright 2014-2018 Chef Software, Inc. -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -# - -name 'liblzma' -default_version '5.2.5' - -license 'Public-Domain' -license_file 'COPYING' -skip_transitive_dependency_licensing true - -# version_list: url=http://tukaani.org/xz/ filer=*.tar.gz - -version('5.2.5') { source sha256: 'f6f4910fd033078738bd82bfba4f49219d03b17eb0794eb91efbae419f4aba10' } -version('5.2.4') { source sha256: 'b512f3b726d3b37b6dc4c8570e137b9311e7552e8ccbab4d39d47ce5f4177145' } -version('5.2.3') { source sha256: '71928b357d0a09a12a4b4c5fafca8c31c19b0e7d3b8ebb19622e96f26dbf28cb' } -version('5.2.2') { source sha256: '73df4d5d34f0468bd57d09f2d8af363e95ed6cc3a4a86129d2f2c366259902a2' } - -source url: "http://tukaani.org/xz/xz-#{version}.tar.gz" - -relative_path "xz-#{version}" - -build do - env = with_standard_compiler_flags(with_embedded_path) - # liblzma properly uses CFLAGS for C compilation and CPPFLAGS for common - # flags used across tools such as windres. Don't put anything in it - # that can be misinterpreted by windres. - env['CPPFLAGS'] = "-I#{install_dir}/embedded/include" if windows? - - config_command = [ - '--disable-debug', - '--disable-dependency-tracking', - '--disable-doc', - '--disable-scripts', - '--disable-lzma-links', - '--disable-lzmainfo', - '--disable-lzmadec', - '--disable-xzdec', - '--disable-xz' - ] - config_command << '--disable-nls' if windows? - - configure(*config_command, env: env) - - make "-j #{workers} install", env: env -end diff --git a/omnibus/config/software/libmnl.rb b/omnibus/config/software/libmnl.rb deleted file mode 100644 index 616433a9b..000000000 --- a/omnibus/config/software/libmnl.rb +++ /dev/null @@ -1,37 +0,0 @@ -# frozen_string_literal: true - -# Copyright Firezone -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -# - -name 'libmnl' -default_version '1.0.4' - -license 'GPL-2.1' -license_file 'COPYING' -skip_transitive_dependency_licensing true - -version('1.0.4') { source sha256: '171f89699f286a5854b72b91d06e8f8e3683064c5901fb09d954a9ab6f551f81' } - -source url: "https://www.netfilter.org/pub/libmnl/libmnl-#{version}.tar.bz2" - -relative_path "#{name}-#{version}" - -build do - env = with_standard_compiler_flags(with_embedded_path) - - command "./configure --prefix=#{install_dir}/embedded", env: env - make "-j #{workers}", env: env - make "-j #{workers} install", env: env -end diff --git a/omnibus/config/software/libnftnl.rb b/omnibus/config/software/libnftnl.rb deleted file mode 100644 index 65c201f3f..000000000 --- a/omnibus/config/software/libnftnl.rb +++ /dev/null @@ -1,37 +0,0 @@ -# frozen_string_literal: true - -# Copyright Firezone -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -# - -name 'libnftnl' -default_version '1.2.2' - -license 'GPL-2.1' -license_file 'COPYING' -skip_transitive_dependency_licensing true - -version('1.2.2') { source sha256: '9efc004f9d15918d68f9e98e194d55e030168f33bb67c3e7a545b740c9ed6d0a' } - -source url: "https://www.netfilter.org/pub/libnftnl/libnftnl-#{version}.tar.bz2" - -relative_path "#{name}-#{version}" - -build do - env = with_standard_compiler_flags(with_embedded_path) - - command "./configure --prefix=#{install_dir}/embedded", env: env - make "-j #{workers}", env: env - make "-j #{workers} install", env: env -end diff --git a/omnibus/config/software/libossp-uuid.rb b/omnibus/config/software/libossp-uuid.rb deleted file mode 100644 index 68331aeef..000000000 --- a/omnibus/config/software/libossp-uuid.rb +++ /dev/null @@ -1,49 +0,0 @@ -# rubocop:disable Naming/FileName -# frozen_string_literal: true - -# -# Copyright 2012-2014 Chef Software, Inc. -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -# - -name 'libossp-uuid' -default_version '1.6.2' - -license 'MIT' -license_file 'README' -skip_transitive_dependency_licensing true - -dependency 'config_guess' - -# version_list: url=https://www.mirrorservice.org/sites/ftp.ossp.org/pkg/lib/uuid/ filter=*.tar.gz - -version('1.6.2') { source sha256: '11a615225baa5f8bb686824423f50e4427acd3f70d394765bdff32801f0fd5b0' } - -# ftp on ftp.ossp.org is unavaiable so we must use another mirror site. -source url: "https://www.mirrorservice.org/sites/ftp.ossp.org/pkg/lib/uuid/uuid-#{version}.tar.gz" - -relative_path "uuid-#{version}" - -build do - env = with_standard_compiler_flags(with_embedded_path) - - update_config_guess - - command './configure' \ - " --prefix=#{install_dir}/embedded", env: env - - make "-j #{workers}", env: env - make "-j #{workers} install", env: env -end -# rubocop:enable Naming/FileName diff --git a/omnibus/config/software/libtool.rb b/omnibus/config/software/libtool.rb deleted file mode 100644 index 89198dcca..000000000 --- a/omnibus/config/software/libtool.rb +++ /dev/null @@ -1,58 +0,0 @@ -# frozen_string_literal: true - -# -# Copyright:: Chef Software, Inc. -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -# - -name 'libtool' -default_version '2.4.6' - -license 'GPL-2.0' -license_file 'COPYING' -skip_transitive_dependency_licensing true - -dependency 'm4' -dependency 'config_guess' - -# version_list: url=https://ftp.gnu.org/gnu/libtool/ filter=*.tar.gz - -version('2.4.6') { source sha256: 'e3bd4d5d3d025a36c21dd6af7ea818a2afcd4dfc1ea5a17b39d7854bcd0c06e3' } -version('2.4.2') { source sha256: 'b38de44862a987293cd3d8dfae1c409d514b6c4e794ebc93648febf9afc38918' } -version('2.4') { source sha256: '13df57ab63a94e196c5d6e95d64e53262834fe780d5e82c28f177f9f71ddf62e' } - -source url: "https://mirrors.kernel.org/gnu/libtool/libtool-#{version}.tar.gz" - -relative_path "libtool-#{version}" - -build do - env = with_standard_compiler_flags(with_embedded_path) - - update_config_guess - update_config_guess(target: 'libltdl/config') - - if aix? - env['M4'] = '/opt/freeware/bin/m4' - elsif solaris2? - # We hit this bug on Solaris11 platforms bug#14291: libtool 2.4.2 fails to build due to macro_revision reversion - # The problem occurs with LANG=en_US.UTF-8 but not with LANG=C - env['LANG'] = 'C' - end - - command './configure' \ - " --prefix=#{install_dir}/embedded", env: env - - make env: env - make 'install', env: env -end diff --git a/omnibus/config/software/libxml2.rb b/omnibus/config/software/libxml2.rb deleted file mode 100644 index c52ed2fe2..000000000 --- a/omnibus/config/software/libxml2.rb +++ /dev/null @@ -1,63 +0,0 @@ -# frozen_string_literal: true - -# -# Copyright:: Chef Software Inc. -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -# - -name 'libxml2' -default_version '2.9.10' # 2.9.12 is not properly building as of 5.20.21 - -license 'MIT' -license_file 'COPYING' -skip_transitive_dependency_licensing true - -dependency 'zlib' -dependency 'liblzma' -dependency 'config_guess' - -# version_list: url=ftp://xmlsoft.org/libxml2/ filter=libxml2-*.tar.gz -version('2.9.12') { source sha256: 'c8d6681e38c56f172892c85ddc0852e1fd4b53b4209e7f4ebf17f7e2eae71d92' } -version('2.9.10') { source sha256: 'aafee193ffb8fe0c82d4afef6ef91972cbaf5feea100edc2f262750611b4be1f' } -version('2.9.9') { source sha256: '94fb70890143e3c6549f265cee93ec064c80a84c42ad0f23e85ee1fd6540a871' } - -source url: "ftp://xmlsoft.org/libxml2/libxml2-#{version}.tar.gz" - -relative_path "libxml2-#{version}" - -build do - env = with_standard_compiler_flags(with_embedded_path) - - configure_command = [ - "--with-zlib=#{install_dir}/embedded", - "--with-lzma=#{install_dir}/embedded", - '--with-sax1', # required for nokogiri to compile - '--without-iconv', - '--without-python', - '--without-icu', - '--without-debug', - '--without-mem-debug', - '--without-run-debug', - '--without-legacy', # we don't need legacy interfaces - '--without-catalog', - '--without-docbook' - ] - - update_config_guess - - configure(*configure_command, env: env) - - make "-j #{workers}", env: env - make "-j #{workers} install", env: env -end diff --git a/omnibus/config/software/libyaml.rb b/omnibus/config/software/libyaml.rb deleted file mode 100644 index afd8e8ac2..000000000 --- a/omnibus/config/software/libyaml.rb +++ /dev/null @@ -1,48 +0,0 @@ -# frozen_string_literal: true - -# -# Copyright 2012-2015 Chef Software, Inc. -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -# - -name 'libyaml' -default_version '0.1.7' - -license 'MIT' -license_file 'LICENSE' - -skip_transitive_dependency_licensing true - -dependency 'config_guess' - -version('0.1.7') { source sha256: '8088e457264a98ba451a90b8661fcb4f9d6f478f7265d48322a196cec2480729' } - -source url: "http://pyyaml.org/download/libyaml/yaml-#{version}.tar.gz" - -relative_path "yaml-#{version}" - -build do - env = with_standard_compiler_flags(with_embedded_path) - - update_config_guess(target: 'config') - - configure '--enable-shared', env: env - - # Windows had worse automake/libtool version issues. - # Just patch the output instead. - patch source: 'v0.1.6.windows-configure.patch', plevel: 1, env: env if version >= '0.1.6' && windows? - - make "-j #{workers}", env: env - make "-j #{workers} install", env: env -end diff --git a/omnibus/config/software/linenoise.rb b/omnibus/config/software/linenoise.rb deleted file mode 100644 index 8d8025b02..000000000 --- a/omnibus/config/software/linenoise.rb +++ /dev/null @@ -1,36 +0,0 @@ -# frozen_string_literal: true - -# Copyright 2012-2014 Firezone -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -# - -name 'linenoise' -description 'A small self-contained alternative to readline and libedit' - -license_file 'LICENSE' -skip_transitive_dependency_licensing true - -source github: 'antirez/linenoise' -default_version 'master' - -build do - env = with_standard_compiler_flags(with_embedded_path) - cc = env.fetch('CC', 'gcc') - - command "#{cc} -c linenoise.c -o linenoise.o -fPIC", env: env - command "#{cc} -shared -o liblinenoise.so linenoise.o -lm", env: env - - copy 'liblinenoise.so', "#{install_dir}/embedded/lib/" - copy 'linenoise.h', "#{install_dir}/embedded/include/" -end diff --git a/omnibus/config/software/m4.rb b/omnibus/config/software/m4.rb deleted file mode 100644 index 52a40bbb9..000000000 --- a/omnibus/config/software/m4.rb +++ /dev/null @@ -1,43 +0,0 @@ -# frozen_string_literal: true - -# -# Copyright:: Chef Software, Inc. -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -# -# expeditor/ignore: deprecated 2021-04 - -name 'm4' -default_version '1.4.19' - -license 'GPL-3.0' -license_file 'COPYING' -skip_transitive_dependency_licensing true - -version('1.4.19') { source sha256: '3be4a26d825ffdfda52a56fc43246456989a3630093cced3fbddf4771ee58a70' } -version('1.4.18') { source sha256: 'ab2633921a5cd38e48797bf5521ad259bdc4b979078034a3b790d7fec5493fab' } - -source url: "https://mirrors.kernel.org/gnu/m4/m4-#{version}.tar.gz" - -relative_path "m4-#{version}" - -build do - env = with_standard_compiler_flags(with_embedded_path) - - patch source: 'm4-1.4.18-glibc-change-work-around.patch', plevel: 1, env: env if version == '1.4.18' - - command "./configure --prefix=#{install_dir}/embedded", env: env - - make "-j #{workers}", env: env - make "-j #{workers} install", env: env -end diff --git a/omnibus/config/software/ncurses.rb b/omnibus/config/software/ncurses.rb deleted file mode 100644 index 9ac9f1ddb..000000000 --- a/omnibus/config/software/ncurses.rb +++ /dev/null @@ -1,160 +0,0 @@ -# frozen_string_literal: true - -# Copyright 2012-2019, Chef Software Inc. -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -# - -name 'ncurses' -default_version '6.2' - -license 'MIT' -license_file 'COPYING' - -# This quickly gets rate-limit and blocked on self-hosted runners. -# license_file "http://invisible-island.net/ncurses/ncurses-license.html" -# license_file "http://invisible-island.net/ncurses/ncurses.faq.html" - -skip_transitive_dependency_licensing true - -dependency 'libtool' -dependency 'config_guess' - -# versions_list: https://ftp.gnu.org/gnu/ncurses/ filter=*.tar.gz -version('6.2') { source sha256: '30306e0c76e0f9f1f0de987cf1c82a5c21e1ce6568b9227f7da5b71cbea86c9d' } -version('6.1') { source sha256: 'aa057eeeb4a14d470101eff4597d5833dcef5965331be3528c08d99cebaa0d17' } -version('5.9') { source sha256: '9046298fb440324c9d4135ecea7879ffed8546dd1b58e59430ea07a4633f563b' } - -source url: "https://mirrors.kernel.org/gnu/ncurses/ncurses-#{version}.tar.gz" - -relative_path "ncurses-#{version}" - -######################################################################## -# -# wide-character support: -# Ruby 1.9 optimistically builds against libncursesw for UTF-8 -# support. In order to prevent Ruby from linking against a -# package-installed version of ncursesw, we build wide-character -# support into ncurses with the "--enable-widec" configure parameter. -# To support other applications and libraries that still try to link -# against libncurses, we also have to create non-wide libraries. -# -# The methods below are adapted from: -# http://www.linuxfromscratch.org/lfs/view/development/chapter06/ncurses.html -# -######################################################################## - -# rubocop:disable Metrics/BlockLength -build do - env = with_standard_compiler_flags(with_embedded_path) - env.delete('CPPFLAGS') - - if smartos? - # SmartOS is Illumos Kernel, plus NetBSD userland with a GNU toolchain. - # These patches are taken from NetBSD pkgsrc and provide GCC 4.7.0 - # compatibility: - # http://ftp.netbsd.org/pub/pkgsrc/current/pkgsrc/devel/ncurses/patches/ - patch source: 'patch-aa', plevel: 0, env: env - patch source: 'patch-ab', plevel: 0, env: env - patch source: 'patch-ac', plevel: 0, env: env - patch source: 'patch-ad', plevel: 0, env: env - patch source: 'patch-cxx_cursesf.h', plevel: 0, env: env - patch source: 'patch-cxx_cursesm.h', plevel: 0, env: env - - # Chef patches - - # The configure script from the pristine tarball detects xopen_source_extended incorrectly. - # Manually working around a false positive. - patch source: 'ncurses-5.9-solaris-xopen_source_extended-detection.patch', plevel: 0, env: env - end - - update_config_guess - - # AIX's old version of patch doesn't like the patches here - if !aix? && (version == '5.9') - # Patch to add support for GCC 5, doesn't break previous versions - patch source: 'ncurses-5.9-gcc-5.patch', plevel: 1, env: env - end - - if mac_os_x? || - # Clang became the default compiler in FreeBSD 10+ - (freebsd? && ohai['os_version'].to_i >= 1_000_024) - # References: - # https://github.com/Homebrew/homebrew-dupes/issues/43 - # http://invisible-island.net/ncurses/NEWS.html#t20110409 - # - # Patches ncurses for clang compiler. Changes have been accepted into - # upstream, but occurred shortly after the 5.9 release. We should be able - # to remove this after upgrading to any release created after June 2012 - patch source: 'ncurses-clang.patch', env: env - end - - patch source: 'patch-ncurses_tinfo_lib__baudrate.c', plevel: 0, env: env if openbsd? - - configure_command = [ - './configure', - "--prefix=#{install_dir}/embedded", - '--enable-overwrite', - '--with-shared', - '--with-termlib', - '--without-ada', - '--without-cxx-binding', - '--without-debug', - '--without-manpages' - ] - - if aix? - # AIX kinda needs 5.9-20140621 or later - # because of a naming snafu in shared library naming. - # see http://invisible-island.net/ncurses/NEWS.html#t20140621 - - # let libtool deal with library silliness - configure_command << "--with-libtool=\"#{install_dir}/embedded/bin/libtool\"" - - # stick with just the shared libs on AIX - configure_command << '--without-normal' - - # ncurses's ./configure incorrectly - # "figures out" ARFLAGS if you try - # to set them yourself - env.delete('ARFLAGS') - - # use gnu install from the coreutils IBM rpm package - env['INSTALL'] = '/opt/freeware/bin/install' - end - - command configure_command.join(' '), env: env - - # unfortunately, libtool may try to link to libtinfo - # before it has been assembled; so we have to build in serial - make 'libs', env: env if aix? - - make "-j #{workers}", env: env - make "-j #{workers} install", env: env - - # Build non-wide-character libraries - make 'distclean', env: env - configure_command << '--enable-widec' - - command configure_command.join(' '), env: env - make 'libs', env: env if aix? - make "-j #{workers}", env: env - - # Installing the non-wide libraries will also install the non-wide - # binaries, which doesn't happen to be a problem since we don't - # utilize the ncurses binaries in private-chef (or oss chef) - make "-j #{workers} install", env: env - - # Ensure embedded ncurses wins in the LD search path - link "#{install_dir}/embedded/lib/libcurses.so", "#{install_dir}/embedded/lib/libcurses.so.1" if smartos? -end -# rubocop:enable Metrics/BlockLength diff --git a/omnibus/config/software/nftables.rb b/omnibus/config/software/nftables.rb deleted file mode 100644 index 9e28bc931..000000000 --- a/omnibus/config/software/nftables.rb +++ /dev/null @@ -1,54 +0,0 @@ -# frozen_string_literal: true - -# Copyright:: Firezone -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -# -name 'nftables' - -license_file 'COPYING' -skip_transitive_dependency_licensing true - -# Some weirdness in the official release package so use git and switch to tag -# default_version "1.0.4" -# source url: "https://www.netfilter.org/pub/nftables/nftables-#{version}.tar.bz2" -# version("1.0.4") { source sha256: "927fb1fea1f685a328c10cf791eb655d7e1ed49d310eea5cb3101dfd8d6cba35" } -source git: 'git://git.netfilter.org/nftables' -default_version 'v1.0.4' - -relative_path "#{name}-#{version}" - -dependency 'gmp' -dependency 'm4' -dependency 'bison' -dependency 'flex' -dependency 'libmnl' -dependency 'libnftnl' -dependency 'libtool' -dependency 'linenoise' -dependency 'pkg-config' - -build do - env = with_standard_compiler_flags(with_embedded_path) - configure_cmd = [ - './configure', - "--prefix=#{install_dir}/embedded", - '--disable-debug', - '--disable-man-doc', - '--with-cli=linenoise' # readline seems to fail to be detected and libedit fails with missing "editline/history.h" - ] - command './autogen.sh', env: env - command configure_cmd.join(' '), env: env - make "-j #{workers}", env: env - make "-j #{workers} install", env: env -end diff --git a/omnibus/config/software/nginx.rb b/omnibus/config/software/nginx.rb deleted file mode 100644 index 9dc4c22c1..000000000 --- a/omnibus/config/software/nginx.rb +++ /dev/null @@ -1,60 +0,0 @@ -# frozen_string_literal: true - -# Copyright 2012-2016 Chef Software, Inc. -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -# - -name 'nginx' -default_version '1.22.0' - -dependency 'pcre' -dependency 'openssl' -dependency 'zlib' -dependency 'acme' - -license 'BSD-2-Clause' -license_file 'LICENSE' - -source url: "https://nginx.org/download/nginx-#{version}.tar.gz" - -# versions_list: https://nginx.org/download/ filter=*.tar.gz -version('1.22.0') { source sha256: 'b33d569a6f11a01433a57ce17e83935e953ad4dc77cdd4d40f896c88ac26eb53' } -version('1.20.1') { source sha256: 'e462e11533d5c30baa05df7652160ff5979591d291736cfa5edb9fd2edb48c49' } -version('1.19.9') { source sha256: '2e35dff06a9826e8aca940e9e8be46b7e4b12c19a48d55bfc2dc28fc9cc7d841' } -version('1.19.8') { source sha256: '308919b1a1359315a8066578472f998f14cb32af8de605a3743acca834348b05' } -version('1.18.0') { source sha256: '4c373e7ab5bf91d34a4f11a0c9496561061ba5eee6020db272a17a7228d35f99' } -version('1.14.2') { source sha256: '002d9f6154e331886a2dd4e6065863c9c1cf8291ae97a1255308572c02be9797' } -version('1.14.0') { source sha256: '5d15becbf69aba1fe33f8d416d97edd95ea8919ea9ac519eff9bafebb6022cb5' } - -relative_path "nginx-#{version}" - -build do - env = with_standard_compiler_flags(with_embedded_path) - - command './configure' \ - " --prefix=#{install_dir}/embedded" \ - ' --with-http_ssl_module' \ - ' --with-http_stub_status_module' \ - ' --with-ipv6' \ - ' --without-pcre2' \ - ' --with-debug' \ - " --with-cc-opt=\"-L#{install_dir}/embedded/lib -I#{install_dir}/embedded/include\"" \ - " --with-ld-opt=-L#{install_dir}/embedded/lib", env: env - - make "-j #{workers}", env: env - make "-j #{workers} install", env: env - - # Ensure the logs directory is available on rebuild from git cache - touch "#{install_dir}/embedded/logs/.gitkeep" -end diff --git a/omnibus/config/software/omnibus-ctl.rb b/omnibus/config/software/omnibus-ctl.rb deleted file mode 100644 index a70b83dec..000000000 --- a/omnibus/config/software/omnibus-ctl.rb +++ /dev/null @@ -1,47 +0,0 @@ -# rubocop:disable Naming/FileName -# frozen_string_literal: true - -# Copyright 2012-2015 Chef Software, Inc. -# Copyright 2017-2021 GitLab Inc. -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -# - -name 'omnibus-ctl' -default_version 'v0.6.0' - -license 'Apache-2.0' -license_file 'https://raw.githubusercontent.com/chef/omnibus-ctl/master/LICENSE' -# Even though omnibus-ctl is a gem, it does not have any dependencies. -skip_transitive_dependency_licensing true - -dependency 'rubygems' -dependency 'ruby' - -# versions_list: https://github.com/chef/omnibus-ctl/tags filter=*.tar.gz -source git: 'https://github.com/chef/omnibus-ctl.git' - -relative_path 'omnibus-ctl' - -build do - env = with_standard_compiler_flags(with_embedded_path) - - # Remove existing built gems in case they exist in the current dir - delete 'omnibus-ctl-*.gem' - - gem 'build omnibus-ctl.gemspec', env: env - gem 'install omnibus-ctl-*.gem --no-document ', env: env - - touch "#{install_dir}/embedded/service/omnibus-ctl/.gitkeep" -end -# rubocop:enable Naming/FileName diff --git a/omnibus/config/software/openssl.rb b/omnibus/config/software/openssl.rb deleted file mode 100644 index e0c135bbd..000000000 --- a/omnibus/config/software/openssl.rb +++ /dev/null @@ -1,177 +0,0 @@ -# frozen_string_literal: true - -# -# Copyright:: Chef Software Inc. -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -# - -name 'openssl' - -license 'OpenSSL' -license_file 'LICENSE' -skip_transitive_dependency_licensing true - -dependency 'cacerts' -dependency 'openssl-fips' if fips_mode? - -default_version '1.1.1k' # do_not_auto_update - -# Openssl builds engines as libraries into a special directory. We need to include -# that directory in lib_dirs so omnibus can sign them during macOS deep signing. -lib_dirs lib_dirs.concat(["#{install_dir}/embedded/lib/engines"]) -lib_dirs lib_dirs.concat(["#{install_dir}/embedded/lib/engines-1.1"]) if version.start_with?('1.1') - -# OpenSSL source ships with broken symlinks which windows doesn't allow. -# So skip error checking with `extract: :lax_tar` -if version.satisfies?('> 1.0.2u') && version.satisfies?('< 1.1.0') - # 1.0.2u was the last public release of 1.0.2. Subsequent releases come from a support contract with OpenSSL - # Software Services - source url: "https://s3.amazonaws.com/chef-releng/openssl/openssl-#{version}.tar.gz", extract: :lax_tar -else - # As of 2020-09-09 even openssl-1.0.0.tar.gz can be downloaded from /source/openssl-VERSION.tar.gz - # However, the latest releases are not in /source/old/VERSION/openssl-VERSION.tar.gz. - # Let's stick with the simpler one for now. - source url: "https://www.openssl.org/source/openssl-#{version}.tar.gz", extract: :lax_tar -end - -version('1.1.1k') { source sha256: '892a0875b9872acd04a9fde79b1f943075d5ea162415de3047c327df33fbaee5' } -version('1.1.1j') { source sha256: 'aaf2fcb575cdf6491b98ab4829abf78a3dec8402b8b81efc8f23c00d443981bf' } -version('1.1.1i') { source sha256: 'e8be6a35fe41d10603c3cc635e93289ed00bf34b79671a3a4de64fcee00d5242' } - -version('1.0.2y') { source sha256: '4882ec99f8e147ab26375da8a6af92efae69b6aef505234764f8cd00a1b81ffc' } -version('1.0.2x') { source sha256: '79cb4e20004a0d1301210aee7e154ddfba3d6a33d0df1f6c5d3257cb915a59c9' } -version('1.0.2w') { source sha256: 'a675ad1a9df59015cebcdf713de76a422347c5d99f11232fe75758143defd680' } -version('1.0.2i') { source sha256: '9287487d11c9545b6efb287cdb70535d4e9b284dd10d51441d9b9963d000de6f' } - -relative_path "openssl-#{version}" - -# rubocop:disable Metrics/BlockLength -build do - env = with_standard_compiler_flags(with_embedded_path) - if aix? - env['M4'] = '/opt/freeware/bin/m4' - elsif mac_os_x? && arm? - env['CFLAGS'] << ' -Qunused-arguments' - elsif freebsd? - # Should this just be in standard_compiler_flags? - env['LDFLAGS'] += " -Wl,-rpath,#{install_dir}/embedded/lib" - elsif windows? - # XXX: OpenSSL explicitly sets -march=i486 and expects that to be honored. - # It has OPENSSL_IA32_SSE2 controlling whether it emits optimized SSE2 code - # and the 32-bit calling convention involving XMM registers is... vague. - # Do not enable SSE2 generally because the hand optimized assembly will - # overwrite registers that mingw expects to get preserved. - env['CFLAGS'] = "-I#{install_dir}/embedded/include" - env['CPPFLAGS'] = env['CFLAGS'] - env['CXXFLAGS'] = env['CFLAGS'] - end - - configure_args = [ - "--prefix=#{install_dir}/embedded", - 'no-unit-test', - 'no-comp', - 'no-idea', - 'no-mdc2', - 'no-rc5', - 'no-ssl2', - 'no-ssl3', - 'no-zlib', - 'shared' - ] - - configure_args += ["--with-fipsdir=#{install_dir}/embedded", 'fips'] if fips_mode? - - configure_cmd = - if aix? - 'perl ./Configure aix64-cc' - elsif mac_os_x? - intel? ? './Configure darwin64-x86_64-cc' : './Configure darwin64-arm64-cc no-asm' - elsif smartos? - '/bin/bash ./Configure solaris64-x86_64-gcc -static-libgcc' - elsif omnios? - '/bin/bash ./Configure solaris-x86-gcc' - elsif solaris2? - platform = sparc? ? 'solaris64-sparcv9-gcc' : 'solaris64-x86_64-gcc' - if version.satisfies?('< 1.1.0') - "/bin/bash ./Configure #{platform} -static-libgcc" - else - "./Configure #{platform} -static-libgcc" - end - elsif windows? - platform = windows_arch_i386? ? 'mingw' : 'mingw64' - "perl.exe ./Configure #{platform}" - else - prefix = - if linux? && ppc64? - './Configure linux-ppc64' - elsif linux? && s390x? - # With gcc > 4.3 on s390x there is an error building - # with inline asm enabled - './Configure linux64-s390x -DOPENSSL_NO_INLINE_ASM' - else - './config' - end - "#{prefix} disable-gost" - end - - patch_env = if aix? - # This enables omnibus to use 'makedepend' - # from fileset 'X11.adt.imake' (AIX install media) - env['PATH'] = "/usr/lpp/X11/bin:#{ENV['PATH']}" - penv = env.dup - penv['PATH'] = "/opt/freeware/bin:#{env['PATH']}" - penv - else - env - end - - if version.start_with? '1.0' - patch source: 'openssl-1.0.1f-do-not-build-docs.patch', env: patch_env - elsif version.start_with? '1.1' - patch source: 'openssl-1.1.0f-do-not-install-docs.patch', env: patch_env - end - - patch source: 'openssl-1.0.2x-darwin-arm64.patch' if version.start_with?('1.0.2') && mac_os_x? && arm? - - if version.start_with?('1.0.2') && windows? - # Patch Makefile.org to update the compiler flags/options table for mingw. - patch source: 'openssl-1.0.1q-fix-compiler-flags-table-for-msys.patch', env: env - end - - # Out of abundance of caution, we put the feature flags first and then - # the crazy platform specific compiler flags at the end. - configure_args << env['CFLAGS'] << env['LDFLAGS'] - - configure_command = configure_args.unshift(configure_cmd).join(' ') - - command configure_command, env: env, in_msys_bash: true - - patch source: 'openssl-1.0.1j-windows-relocate-dll.patch', env: env if version.start_with?('1.0.2') && windows? - - make 'depend', env: env - # make -j N on openssl is not reliable - make "-j #{workers}", env: env - if aix? - # We have to sudo this because you can't actually run slibclean without being root. - # Something in openssl changed in the build process so now it loads the libcrypto - # and libssl libraries into AIX's shared library space during the first part of the - # compile. This means we need to clear the space since it's not being used and we - # can't install the library that is already in use. Ideally we would patch openssl - # to make this not be an issue. - # Bug Ref: http://rt.openssl.org/Ticket/Display.html?id=2986&user=guest&pass=guest - command 'sudo /usr/sbin/slibclean', env: env - end - make "-j #{workers} install", env: env -end -# rubocop:enable Metrics/BlockLength diff --git a/omnibus/config/software/pcre.rb b/omnibus/config/software/pcre.rb deleted file mode 100644 index d0de3a34b..000000000 --- a/omnibus/config/software/pcre.rb +++ /dev/null @@ -1,54 +0,0 @@ -# frozen_string_literal: true - -# -# Copyright:: Chef Software, Inc. -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -# - -name 'pcre' -default_version '8.44' - -license 'BSD-2-Clause' -license_file 'LICENCE' -skip_transitive_dependency_licensing true - -dependency 'libedit' -dependency 'ncurses' -dependency 'config_guess' - -# version_list: url=https://sourceforge.net/projects/pcre/files/pcre/ filter=*.tar.gz - -version('8.44') { source sha256: 'aecafd4af3bd0f3935721af77b889d9024b2e01d96b58471bd91a3063fb47728' } -version('8.38') { source sha256: '9883e419c336c63b0cb5202b09537c140966d585e4d0da66147dc513da13e629' } - -source url: "http://downloads.sourceforge.net/project/pcre/pcre/#{version}/pcre-#{version}.tar.gz" - -relative_path "pcre-#{version}" - -build do - env = with_standard_compiler_flags(with_embedded_path) - - update_config_guess - - command './configure' \ - " --prefix=#{install_dir}/embedded" \ - ' --disable-cpp' \ - ' --enable-utf' \ - ' --enable-unicode-properties' \ - ' --enable-pcretest-libedit' \ - '--disable-pcregrep-jit', env: env - - make "-j #{workers}", env: env - make "-j #{workers} install", env: env -end diff --git a/omnibus/config/software/perl-thread-queue.rb b/omnibus/config/software/perl-thread-queue.rb deleted file mode 100644 index 1908db5ec..000000000 --- a/omnibus/config/software/perl-thread-queue.rb +++ /dev/null @@ -1,44 +0,0 @@ -# rubocop:disable Naming/FileName -# frozen_string_literal: true - -# -# Copyright 2019 Oregon State University -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -# -# expeditor/ignore: deprecated 2021-04 - -name 'perl-thread-queue' -default_version '3.13' - -dependency 'perl' - -version '3.13' do - source sha256: '6ba3dacddd2fbb66822b4aa1d11a0a5273cd04c825cb3ff31c20d7037cbfdce8' -end - -source url: "http://search.cpan.org/CPAN/authors/id/J/JD/JDHEDDEN/Thread-Queue-#{version}.tar.gz" - -relative_path "Thread-Queue-#{version}" - -build do - env = with_standard_compiler_flags(with_embedded_path).merge( - 'INSTALL_BASE' => "#{install_dir}/embedded" - ) - - command "#{install_dir}/embedded/bin/perl Makefile.PL", env: env - - make env: env - make 'install', env: env -end -# rubocop:enable Naming/FileName diff --git a/omnibus/config/software/perl.rb b/omnibus/config/software/perl.rb deleted file mode 100644 index 11f8d1c67..000000000 --- a/omnibus/config/software/perl.rb +++ /dev/null @@ -1,78 +0,0 @@ -# frozen_string_literal: true - -# -# Copyright:: Chef Software, Inc. -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -# - -name 'perl' - -license 'Artistic-2.0' -license_file 'Artistic' -skip_transitive_dependency_licensing true - -default_version '5.34.0' - -# versions_list: http://www.cpan.org/src/ filter=*.tar.gz -version('5.34.0') { source sha256: '551efc818b968b05216024fb0b727ef2ad4c100f8cb6b43fab615fa78ae5be9a' } -version('5.32.1') { source sha256: '03b693901cd8ae807231b1787798cf1f2e0b8a56218d07b7da44f784a7caeb2c' } -version('5.30.0') { source sha256: '851213c754d98ccff042caa40ba7a796b2cee88c5325f121be5cbb61bbf975f2' } -version('5.22.1') { source sha256: '2b475d0849d54c4250e9cba4241b7b7291cffb45dfd083b677ca7b5d38118f27' } -version('5.18.1') { source sha256: '655e11a8ffba8853efcdce568a142c232600ed120ac24aaebb4e6efe74e85b2b' } -source url: "http://www.cpan.org/src/5.0/perl-#{version}.tar.gz" - -# perl builds perl as libraries into a special directory. We need to include -# that directory in lib_dirs so omnibus can sign them during macOS deep signing. -lib_dirs lib_dirs.concat ["#{install_dir}/embedded/lib/perl5/**"] - -relative_path "perl-#{version}" - -# rubocop:disable Metrics/BlockLength -build do - env = with_standard_compiler_flags(with_embedded_path) - - patch source: "perl-#{version}-remove_lnsl.patch", plevel: 1, env: env - - cc_command = if solaris2? - "-Dcc='gcc -m64 -static-libgcc'" - elsif aix? - "-Dcc='/opt/IBM/xlc/13.1.0/bin/cc_r -q64'" - elsif freebsd? && ohai['os_version'].to_i >= 1_000_024 - "-Dcc='clang'" - elsif mac_os_x? - "-Dcc='clang'" - else - "-Dcc='gcc -static-libgcc'" - end - - configure_command = ['sh Configure', - ' -de', - " -Dprefix=#{install_dir}/embedded", - ' -Duseshrplib', - ' -Dusethreads', - " #{cc_command}", - " -Dnoextensions='DB_File GDBM_File NDBM_File ODBM_File'"] - - if aix? - configure_command << '-Dmake=gmake' - configure_command << '-Duse64bitall' - end - - command configure_command.join(' '), env: env - make "-j #{workers}", env: env - # using the install.perl target lets - # us skip install the manpages - make 'install.perl', env: env -end -# rubocop:enable Metrics/BlockLength diff --git a/omnibus/config/software/pkg-config.rb b/omnibus/config/software/pkg-config.rb deleted file mode 100644 index de602034c..000000000 --- a/omnibus/config/software/pkg-config.rb +++ /dev/null @@ -1,66 +0,0 @@ -# rubocop:disable Naming/FileName -# frozen_string_literal: true - -# -# Copyright 2013-2014 Chef Software, Inc. -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -# -# expeditor/ignore: deprecated 2021-05 - -name 'pkg-config' -default_version '0.28' - -dependency 'libiconv' -dependency 'config_guess' - -# version_list: url=https://pkgconfig.freedesktop.org/releases/ filter=*.tar.gz - -version('0.28') { source sha256: '6b6eb31c6ec4421174578652c7e141fdaae2dabad1021f420d8713206ac1f845' } - -source url: "https://pkgconfig.freedesktop.org/releases/pkg-config-#{version}.tar.gz" - -relative_path "pkg-config-#{version}" - -build do - env = with_standard_compiler_flags(with_embedded_path) - - update_config_guess - - # pkg-config (at least up to 0.28) includes an older version of - # libcharset/lib/config.charset that doesn't know about openbsd - patch source: 'openbsd-charset.patch', plevel: 1, env: env if openbsd? - - command './configure' \ - " --prefix=#{install_dir}/embedded" \ - ' --disable-debug' \ - ' --disable-host-tool' \ - ' --with-internal-glib' \ - " --with-pc-path=#{install_dir}/embedded/bin/pkgconfig", env: env - - # #203: pkg-configs internal glib does not provide a way to pass ldflags. - # Only allows GLIB_CFLAGS and GLIB_LIBS. - # These do not serve our purpose, so we must explicitly - # ./configure in the glib dir, with the Omnibus ldflags. - command './configure' \ - " --prefix=#{install_dir}/embedded" \ - ' --with-libiconv=gnu', env: env, cwd: "#{project_dir}/glib" - - make "-j #{workers}", env: env - make "-j #{workers} install", env: env - - # ensure charset.alias gets installed on openbsd else pkg-config will - # exit with byte conversion errors. - copy "#{project_dir}/glib/glib/libcharset/charset.alias", "#{install_dir}/embedded/lib/charset.alias" if openbsd? -end -# rubocop:enable Naming/FileName diff --git a/omnibus/config/software/postgresql.rb b/omnibus/config/software/postgresql.rb deleted file mode 100644 index 78bf64d35..000000000 --- a/omnibus/config/software/postgresql.rb +++ /dev/null @@ -1,79 +0,0 @@ -# frozen_string_literal: true - -# Copyright:: Chef Software, Inc. -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -# - -name 'postgresql' -default_version '13.8' - -license 'PostgreSQL' -license_file 'COPYRIGHT' -skip_transitive_dependency_licensing true - -dependency 'autoconf' -dependency 'automake' -dependency 'm4' -dependency 'pkg-config' -dependency 'zlib' -dependency 'openssl' -dependency 'libedit' -dependency 'libossp-uuid' -dependency 'ncurses' -dependency 'config_guess' - -# version_list: url=https://ftp.postgresql.org/pub/source/v#{version}/ filter=*.tar.bz2 - -version('13.8') { source sha256: '73876fdd3a517087340458dca4ce15b8d2a4dbceb334c0441424551ae6c4cded' } -version('13.5') { source sha256: '9b81067a55edbaabc418aacef457dd8477642827499560b00615a6ea6c13f6b3' } -version('13.3') { source sha256: '3cd9454fa8c7a6255b6743b767700925ead1b9ab0d7a0f9dcb1151010f8eb4a1' } - -# Version 12.x will EoL November 14, 2024 -version('12.7') { source sha256: '8490741f47c88edc8b6624af009ce19fda4dc9b31c4469ce2551d84075d5d995' } - -# Version 9.6 will EoL November 11, 2021 -version('9.6.22') { source sha256: '3d32cd101025a0556813397c69feff3df3d63736adb8adeaf365c522f39f2930' } - -# Version 9.3 was EoL November 8, 2018 (but used in Supermarket as of 6.2021) -version('9.3.25') { source sha256: 'e4953e80415d039ccd33d34be74526a090fd585cf93f296cd9c593972504b6db' } - -source url: "https://ftp.postgresql.org/pub/source/v#{version}/postgresql-#{version}.tar.bz2" - -relative_path "postgresql-#{version}" - -build do - env = with_standard_compiler_flags(with_embedded_path) - - update_config_guess(target: 'config') - - configure_command = [ - './configure', - "--prefix=#{install_dir}/embedded", - '--with-libedit-preferred', - '--with-openssl', - '--enable-thread-safety', - "--with-includes=#{install_dir}/embedded/include", - "--with-libraries=#{install_dir}/embedded/lib" - ] - - if linux? - configure_command << '--with-uuid=ossp' - elsif mac_os_x? - configure_command << '--with-uuid=e2fs' - end - - command configure_command.join(' '), env: env - make "world -j #{workers}", env: env - make 'install-world', env: env -end diff --git a/omnibus/config/software/readline.rb b/omnibus/config/software/readline.rb deleted file mode 100644 index 09d90263b..000000000 --- a/omnibus/config/software/readline.rb +++ /dev/null @@ -1,39 +0,0 @@ -# frozen_string_literal: true - -# Copyright:: Firezone, Inc. -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -name 'readline' - -default_version '8.1' - -version('8.1') { source sha256: 'f8ceb4ee131e3232226a17f51b164afc46cd0b9e6cef344be87c65962cb82b02' } - -source url: "https://mirrors.kernel.org/gnu/readline/readline-#{version}.tar.gz" - -dependency 'config_guess' - -relative_path "readline-#{version}" - -build do - env = with_standard_compiler_flags(with_embedded_path) - update_config_guess - configure_command = ['./configure', - '--disable-mpfr', - "--prefix=#{install_dir}/embedded"] - - command configure_command.join(' '), env: env - make "-j #{workers}", env: env - make "-j #{workers} install", env: env -end diff --git a/omnibus/config/software/ruby.rb b/omnibus/config/software/ruby.rb deleted file mode 100644 index 0bbe2e2fd..000000000 --- a/omnibus/config/software/ruby.rb +++ /dev/null @@ -1,247 +0,0 @@ -# frozen_string_literal: true - -# -# Copyright 2012-2016 Chef Software, Inc. -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -# - -name 'ruby' -license 'BSD-2-Clause' -license_file 'BSDL' -license_file 'COPYING' -license_file 'LEGAL' - -skip_transitive_dependency_licensing true - -# - chef-client cannot use 2.2.x yet due to a bug in IRB that affects chef-shell on linux: -# https://bugs.ruby-lang.org/issues/11869 -# - the current status of 2.3.x is that it downloads but fails to compile. -# - verify that all ffi libs are available for your version on all platforms. -# - when upgrading please check the ABI version and update the exclusion until -# https://gitlab.com/gitlab-org/omnibus-gitlab/issues/3414 is addressed -default_version '2.7.6' - -fips_enabled = (project.overrides[:fips] && project.overrides[:fips][:enabled]) || false - -dependency 'patch' if solaris? && platform_version.satisfies?('10') -dependency 'ncurses' unless windows? || version.satisfies?('>= 2.1') -dependency 'zlib' -dependency 'openssl' -dependency 'libffi' -dependency 'libyaml' -# Needed for chef_gem installs of (e.g.) nokogiri on upgrades - -# they expect to see our libiconv instead of a system version. -# Ignore on windows - TDM GCC comes with libiconv in the runtime -# and that's the only one we will ever use. -dependency 'libiconv' - -version('2.7.6') { source sha256: 'e7203b0cc09442ed2c08936d483f8ac140ec1c72e37bb5c401646b7866cb5d10' } -version('2.7.5') { source sha256: '2755b900a21235b443bb16dadd9032f784d4a88f143d852bc5d154f22b8781f1' } -version('2.7.4') { source sha256: '3043099089608859fc8cce7f9fdccaa1f53a462457e3838ec3b25a7d609fbc5b' } -version('2.7.3') { source sha256: '8925a95e31d8f2c81749025a52a544ea1d05dad18794e6828709268b92e55338' } -version('2.7.2') { source sha256: '6e5706d0d4ee4e1e2f883db9d768586b4d06567debea353c796ec45e8321c3d4' } - -source url: "https://cache.ruby-lang.org/pub/ruby/#{version.match(/^(\d+\.\d+)/)[0]}/ruby-#{version}.tar.gz" - -relative_path "ruby-#{version}" - -env = with_standard_compiler_flags(with_embedded_path) - -if mac_os_x? - # -Qunused-arguments suppresses "argument unused during compilation" - # warnings. These can be produced if you compile a program that doesn't - # link to anything in a path given with -Lextra-libs. Normally these - # would be harmless, except that autoconf treats any output to stderr as - # a failure when it makes a test program to check your CFLAGS (regardless - # of the actual exit code from the compiler). - env['CFLAGS'] << " -I#{install_dir}/embedded/include/ncurses -arch x86_64 -m64 -O3 -g -pipe -Qunused-arguments" - env['LDFLAGS'] << ' -arch x86_64' -elsif freebsd? - # Stops "libtinfo.so.5.9: could not read symbols: Bad value" error when - # compiling ext/readline. See the following for more info: - - # https://lists.freebsd.org/pipermail/freebsd-current/2013-October/045425.html - # http://mailing.freebsd.ports-bugs.narkive.com/kCgK8sNQ/ports-183106-patch-sysutils-libcdio-does-not-build-on-10-0-and-head - # - env['LDFLAGS'] << ' -ltinfow' -elsif aix? - # this magic per IBM - env['LDSHARED'] = 'xlc -G' - env['CFLAGS'] = "-I#{install_dir}/embedded/include/ncurses -I#{install_dir}/embedded/include" - # this magic per IBM - env['XCFLAGS'] = '-DRUBY_EXPORT' - # need CPPFLAGS set so ruby doesn't try to be too clever - env['CPPFLAGS'] = "-I#{install_dir}/embedded/include/ncurses -I#{install_dir}/embedded/include" - env['SOLIBS'] = '-lm -lc' - # need to use GNU m4, default m4 doesn't work - env['M4'] = '/opt/freeware/bin/m4' -elsif solaris? && platform_version.satisfies?('10') - if sparc? - # Known issue with rubby where too much GCC optimization blows up miniruby on sparc - env['CFLAGS'] << ' -std=c99 -O0 -g -pipe -mcpu=v9' - env['LDFLAGS'] << ' -mcpu=v9' - else - env['CFLAGS'] << ' -std=c99 -O3 -g -pipe' - end -elsif windows? - env['CPPFLAGS'] << ' -DFD_SETSIZE=2048' -else # including linux - env['CFLAGS'] << if version.satisfies?('>= 2.3.0') && - rhel? && platform_version.satisfies?('< 6.0') - ' -O2 -g -pipe' - else - ' -O3 -g -pipe' - end -end - -# rubocop:disable Metrics/BlockLength -build do - env['CFLAGS'] << ' -fno-omit-frame-pointer' - - # AIX needs /opt/freeware/bin only for patch - patch_env = env.dup - patch_env['PATH'] = "/opt/freeware/bin:#{env['PATH']}" if aix? - - if solaris? && platform_version.satisfies?('10') && version.satisfies?('>= 2.1') - patch source: 'ruby-no-stack-protector.patch', plevel: 1, env: patch_env - elsif solaris? && platform_version.satisfies?('10') && version =~ /^1.9/ - patch source: 'ruby-sparc-1.9.3-c99.patch', plevel: 1, env: patch_env - elsif solaris? && platform_version.satisfies?('11') && version =~ /^2.1/ - patch source: 'ruby-solaris-linux-socket-compat.patch', plevel: 1, env: patch_env - end - - # wrlinux7/ios_xr build boxes from Cisco include libssp and there is no way to - # disable ruby from linking against it, but Cisco switches will not have the - # library. Disabling it as we do for Solaris. - # TODO: Failing with "undefined method "ios_xr?". Not supporting Cisco switches yet. - # patch source: 'ruby-no-stack-protector.patch', plevel: 1, env: patch_env if ios_xr? && version.satisfies?('>= 2.1') - - # disable libpath in mkmf across all platforms, it trolls omnibus and - # breaks the postgresql cookbook. i'm not sure why ruby authors decided - # this was a good idea, but it breaks our use case hard. AIX cannot even - # compile without removing it, and it breaks some native gem installs on - # other platforms. generally you need to have a condition where the - # embedded and non-embedded libs get into a fight (libiconv, openssl, etc) - # and ruby trying to set LD_LIBRARY_PATH itself gets it wrong. - # - # Also, fix paths emitted in the makefile on windows on both msys and msys2. - if version.satisfies?('>= 2.1') - patch source: 'ruby-mkmf.patch', plevel: 1, env: patch_env - # should intentionally break and fail to apply on 2.2, patch will need to - # be fixed. - end - - # Enable custom patch created by ayufan that allows to count memory allocations - # per-thread. This is asked to be upstreamed as part of https://github.com/ruby/ruby/pull/3978 - patch source: 'thread-memory-allocations-2.7.patch', plevel: 1, env: patch_env - - # Fix reserve stack segmentation fault when building on RHEL5 or below - # Currently only affects 2.1.7 and 2.2.3. This patch taken from the fix - # in Ruby trunk and expected to be included in future point releases. - # https://redmine.ruby-lang.org/issues/11602 - if rhel? && - platform_version.satisfies?('< 6') && - (version == '2.1.7' || version == '2.2.3') - - patch source: 'ruby-fix-reserve-stack-segfault.patch', plevel: 1, env: patch_env - end - - # copy_file_range() has been disabled on recent RedHat kernels: - # 1. https://gitlab.com/gitlab-org/gitlab/-/issues/218999 - # 2. https://bugs.ruby-lang.org/issues/16965 - # 3. https://bugzilla.redhat.com/show_bug.cgi?id=1783554 - patch source: 'ruby-disable-copy-file-range.patch', plevel: 1, env: patch_env if centos? || rhel? - - configure_command = ['--with-out-ext=dbm,readline', - '--enable-shared', - '--disable-install-doc', - '--without-gmp', - '--without-gdbm', - '--without-tk', - '--disable-dtrace'] - configure_command << '--with-ext=psych' if version.satisfies?('< 2.3') - configure_command << '--with-bundled-md5' if fips_enabled - - if aix? - # need to patch ruby's configure file so it knows how to find shared libraries - patch source: 'ruby-aix-configure.patch', plevel: 1, env: patch_env - # have ruby use zlib on AIX correctly - patch source: 'ruby_aix_openssl.patch', plevel: 1, env: patch_env - # AIX has issues with ssl retries, need to patch to have it retry - patch source: 'ruby_aix_2_1_3_ssl_EAGAIN.patch', plevel: 1, env: patch_env - # the next two patches are because xlc doesn't deal with long vs int types well - patch source: 'ruby-aix-atomic.patch', plevel: 1, env: patch_env - patch source: 'ruby-aix-vm-core.patch', plevel: 1, env: patch_env - - # per IBM, just help ruby along on what it's running on - configure_command << '--host=powerpc-ibm-aix6.1.0.0 --target=powerpc-ibm-aix6.1.0.0 --build=powerpc-ibm-aix6'\ - '.1.0.0 --enable-pthread' - - elsif freebsd? - # Disable optional support C level backtrace support. This requires the - # optional devel/libexecinfo port to be installed. - configure_command << 'ac_cv_header_execinfo_h=no' - configure_command << "--with-opt-dir=#{install_dir}/embedded" - elsif smartos? - # Opscode patch - someara@opscode.com - # GCC 4.7.0 chokes on mismatched function types between OpenSSL 1.0.1c and Ruby 1.9.3-p286 - patch source: 'ruby-openssl-1.0.1c.patch', plevel: 1, env: patch_env - - # Patches taken from RVM. - # http://bugs.ruby-lang.org/issues/5384 - # https://www.illumos.org/issues/1587 - # https://github.com/wayneeseguin/rvm/issues/719 - patch source: 'rvm-cflags.patch', plevel: 1, env: patch_env - - # From RVM forum - # https://github.com/wayneeseguin/rvm/commit/86766534fcc26f4582f23842a4d3789707ce6b96 - configure_command << 'ac_cv_func_dl_iterate_phdr=no' - configure_command << "--with-opt-dir=#{install_dir}/embedded" - elsif windows? - configure_command << ' debugflags=-g' - else - # TODO: Consider pulling in Gitlab's OhaiHelper if raspberry_pi is needed - # configure_command << %w(host target build).map { |w| "--#{w}=#{OhaiHelper.gcc_target}" } if \ - # OhaiHelper.raspberry_pi? - configure_command << "--with-opt-dir=#{install_dir}/embedded" - end - - # FFS: works around a bug that infects AIX when it picks up our pkg-config - # AFAIK, ruby does not need or use this pkg-config it just causes the build to fail. - # The alternative would be to patch configure to remove all the pkg-config garbage entirely - env['PKG_CONFIG'] = '/bin/true' if aix? - - configure(*configure_command, env: env) - make "-j #{workers}", env: env - make "-j #{workers} install", env: env - - if windows? - # Needed now that we switched to msys2 and have not figured out how to tell - # it how to statically link yet - dlls = ['libwinpthread-1'] - dlls << if windows_arch_i386? - 'libgcc_s_dw2-1' - else - 'libgcc_s_seh-1' - end - dlls.each do |dll| - arch_suffix = windows_arch_i386? ? '32' : '64' - windows_path = "C:/msys2/mingw#{arch_suffix}/bin/#{dll}.dll" - raise "Cannot find required DLL needed for dynamic linking: #{windows_path}" unless File.exist?(windows_path) - - copy windows_path, "#{install_dir}/embedded/bin/#{dll}.dll" - end - end -end -# rubocop:enable Metrics/BlockLength diff --git a/omnibus/config/software/rubygems.rb b/omnibus/config/software/rubygems.rb deleted file mode 100644 index e398621b8..000000000 --- a/omnibus/config/software/rubygems.rb +++ /dev/null @@ -1,88 +0,0 @@ -# frozen_string_literal: true - -# -# Copyright 2012-2016 Chef Software, Inc. -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -# - -name 'rubygems' -default_version '3.1.4' - -license 'MIT' -license_file 'LICENSE.txt' - -skip_transitive_dependency_licensing true - -dependency 'ruby' - -if version && !source - # NOTE: 2.1.11 is the last version of rubygems before the 2.2.x change to native gem install location - # - # https://github.com/rubygems/rubygems/issues/874 - # - # This is a breaking change for omnibus clients. Chef-11 needs to be pinned to 2.1.11 for eternity. - # We have switched from tarballs to just `gem update --system`, but for backcompat - # we pin the previously known tarballs. - known_tarballs = { - '2.1.11' => 'b561b7aaa70d387e230688066e46e448', - '2.2.1' => '1f0017af0ad3d3ed52665132f80e7443', - '2.4.1' => '7e39c31806bbf9268296d03bd97ce718', - '2.4.4' => '440a89ad6a3b1b7a69b034233cc4658e', - '2.4.5' => '5918319a439c33ac75fbbad7fd60749d', - '2.4.8' => 'dc77b51449dffe5b31776bff826bf559', - '2.7.9' => '173272ed55405caf7f858b6981fff526', - '3.1.4' => 'd117187a8f016cbe8f52011ae02e858b' - } - known_tarballs.each do |version, md5| - version version do - source md5: md5, url: "https://rubygems.org/rubygems/rubygems-#{version}.tgz" - relative_path "rubygems-#{version}" - end - end - - version('v2.4.4_plus_debug') { source git: 'https://github.com/danielsdeleo/rubygems.git' } - version('2.4.4.debug.1') { source git: 'https://github.com/danielsdeleo/rubygems.git' } - # This is the 2.4.8 release with a fix for - # windows so things like `gem install "pry"` still - # work - version('jdm/2.4.8-patched') { source git: 'https://github.com/jaym/rubygems.git' } -end - -# If we still don't have a source (if it's a tarball) grab from ruby ... -if version && !source - # If the version is a gem version, we"ll just be using rubygems. - # If it's a branch or SHA (i.e. v1.2.3) we use github. - begin - Gem::Version.new(version) - rescue ArgumentError - source git: 'https://github.com/rubygems/rubygems.git' - end -end - -# git repo is always expanded to "rubygems" -relative_path 'rubygems' if source&.include?(:git) - -build do - env = with_standard_compiler_flags(with_embedded_path) - - if source - # Building from source: - ruby 'setup.rb --no-document', env: env - else - # Installing direct from rubygems: - # If there is no version, this will get latest. - gem "update --system #{version}", env: env - patch source: 'license/add-license-file.patch' - end -end diff --git a/omnibus/config/software/runit.rb b/omnibus/config/software/runit.rb deleted file mode 100644 index f28727598..000000000 --- a/omnibus/config/software/runit.rb +++ /dev/null @@ -1,77 +0,0 @@ -# frozen_string_literal: true - -# Copyright 2012-2014 Chef Software, Inc. -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -# - -name 'runit' -default_version '2.1.2' - -license 'BSD-3-Clause' -license_file '../package/COPYING' - -skip_transitive_dependency_licensing true - -version '2.1.2' do - source md5: '6c985fbfe3a34608eb3c53dc719172c4' -end - -source url: "http://smarden.org/runit/runit-#{version}.tar.gz" - -relative_path "admin/runit-#{version}/src" - -build do - # Patch runit to not consider status of log service associated with a service - # on determining output of status command. For details, check - # https://gitlab.com/gitlab-org/omnibus-gitlab/issues/4008 - patch source: 'log-status.patch' - - env = with_standard_compiler_flags(with_embedded_path) - - # Put runit where we want it, not where they tell us to - # rubocop:disable Style/StringConcatenation - cmd = 'sed -i -e "s/^char\ \*varservice\ \=\"\/service\/\";$/char\ \*varservice\ \=\"' + \ - install_dir.gsub('/', '\\/') + '\/service\/\";/" sv.c' - # rubocop:enable Style/StringConcatenation - command cmd, env: env - - # TODO: the following is not idempotent - command 'sed -i -e s:-static:: Makefile', env: env - - # Build it - make "-j #{workers}", env: env - make "-j #{workers} check", env: env - - # Move it - mkdir "#{install_dir}/embedded/bin" - copy "#{project_dir}/chpst", "#{install_dir}/embedded/bin" - copy "#{project_dir}/runit", "#{install_dir}/embedded/bin" - copy "#{project_dir}/runit-init", "#{install_dir}/embedded/bin" - copy "#{project_dir}/runsv", "#{install_dir}/embedded/bin" - copy "#{project_dir}/runsvchdir", "#{install_dir}/embedded/bin" - copy "#{project_dir}/runsvdir", "#{install_dir}/embedded/bin" - copy "#{project_dir}/sv", "#{install_dir}/embedded/bin" - copy "#{project_dir}/svlogd", "#{install_dir}/embedded/bin" - copy "#{project_dir}/utmpset", "#{install_dir}/embedded/bin" - - erb source: 'runsvdir-start.erb', - dest: "#{install_dir}/embedded/bin/runsvdir-start", - mode: 0o755, - vars: { install_dir: install_dir } - - # Setup service directories - touch "#{install_dir}/service/.gitkeep" - touch "#{install_dir}/sv/.gitkeep" - touch "#{install_dir}/init/.gitkeep" -end diff --git a/omnibus/config/software/zlib.rb b/omnibus/config/software/zlib.rb deleted file mode 100644 index 02d8266ee..000000000 --- a/omnibus/config/software/zlib.rb +++ /dev/null @@ -1,85 +0,0 @@ -# frozen_string_literal: true - -# -# Copyright 2012-2018 Chef Software, Inc. -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -# - -name 'zlib' -default_version '1.2.11' - -# version_list: url=https://zlib.net/fossils/ filter=*.tar.gz - -version('1.2.11') { source sha256: 'c3e5e9fdd5004dcb542feda5ee4f0ff0744628baf8ed2dd5d66f8ca1197cb1a1' } -version('1.2.8') { source sha256: '36658cb768a54c1d4dec43c3116c27ed893e88b02ecfcb44f2166f9c0b7f2a0d' } -version('1.2.6') { source sha256: '21235e08552e6feba09ea5e8d750805b3391c62fb81c71a235c0044dc7a8a61b' } - -source url: "https://zlib.net/fossils/zlib-#{version}.tar.gz" - -license 'Zlib' -license_file 'README' -skip_transitive_dependency_licensing true - -relative_path "zlib-#{version}" - -build do - if windows? - env = with_standard_compiler_flags(with_embedded_path) - - patch source: 'zlib-windows-relocate.patch', env: env - - # We can't use the top-level Makefile. Instead, the developers have made - # an organic, artisanal, hand-crafted Makefile.gcc for us which takes a few - # variables. - env['BINARY_PATH'] = '/bin' - env['LIBRARY_PATH'] = '/lib' - env['INCLUDE_PATH'] = '/include' - env['DESTDIR'] = "#{install_dir}/embedded" - - make_args = [ - '-fwin32/Makefile.gcc', - 'SHARED_MODE=1', - "CFLAGS=\"#{env['CFLAGS']} -Wall\"", - "ASFLAGS=\"#{env['CFLAGS']} -Wall\"", - "LDFLAGS=\"#{env['LDFLAGS']}\"" - # The win32 makefile for zlib does not handle parallel make correctly. - # In particular, see its rule for IMPLIB and SHAREDLIB. The ld step in - # SHAREDLIB will generate both the dll and the dll.a files. The step to - # strip the dll occurs next but since the dll.a file is already present, - # make will attempt to link example_d.exe and minigzip_d.exe in parallel - # with the strip step - causing gcc to freak out when a source file is - # rewritten part way through the linking stage. - # "-j #{workers}", - ] - - make(*make_args, env: env) - make('install', *make_args, env: env) - else - # We omit the omnibus path here because it breaks mac_os_x builds by picking - # up the embedded libtool instead of the system libtool which the zlib - # configure script cannot handle. - # TODO: Do other OSes need this? Is this strictly a mac thing? - env = with_standard_compiler_flags - if freebsd? - # FreeBSD 10+ gets cranky if zlib is not compiled in a - # position-independent way. - env['CFLAGS'] << ' -fPIC' - end - - configure env: env - - make "-j #{workers}", env: env - make "-j #{workers} install", env: env - end -end diff --git a/omnibus/config/templates/firezone-ctl/firezone-ctl.erb b/omnibus/config/templates/firezone-ctl/firezone-ctl.erb deleted file mode 100644 index d89e591ff..000000000 --- a/omnibus/config/templates/firezone-ctl/firezone-ctl.erb +++ /dev/null @@ -1,34 +0,0 @@ -#!/bin/bash -# -# Copyright 2014 Chef Software, Inc. -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -# - -# Ensure the calling environment (disapproval look Bundler) does not infect our -# Ruby environment if called from a Ruby script. -for ruby_env_var in RUBYOPT \ - BUNDLE_BIN_PATH \ - BUNDLE_GEMFILE \ - GEM_PATH \ - GEM_ROOT \ - GEM_HOME -do - unset $ruby_env_var -done - -# This bumps the default svwait timeout from 7 seconds to 30 seconds -# As documented at http://smarden.org/runit/sv.8.html -export SVWAIT=30 - -<%= embedded_bin %>/omnibus-ctl firezone <%= embedded_service %>/omnibus-ctl $@ diff --git a/omnibus/config/templates/runit/runsvdir-start.erb b/omnibus/config/templates/runit/runsvdir-start.erb deleted file mode 100644 index db6d40acb..000000000 --- a/omnibus/config/templates/runit/runsvdir-start.erb +++ /dev/null @@ -1,42 +0,0 @@ -#!/bin/sh -# -# Copyright 2012-<%= Time.now.year %> Chef Software, Inc. -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -# - -PATH=<%= install_dir %>/bin:<%= install_dir %>/embedded/bin:/usr/local/bin:/usr/local/sbin:/bin:/sbin:/usr/bin:/usr/sbin - -ulimit -c 0 -ulimit -d unlimited -ulimit -e 0 -ulimit -f unlimited -ulimit -i 62793 -ulimit -l 64 -ulimit -m unlimited -# WARNING: Increasing the global file descriptor limit increases RAM -# consumption on startup dramatically! -ulimit -n 50000 -ulimit -q 819200 -ulimit -r 0 -ulimit -s 10240 -ulimit -t unlimited -ulimit -u unlimited -ulimit -v unlimited -ulimit -x unlimited -echo "1000000" > /proc/sys/fs/file-max - -umask 022 - -exec env - PATH=$PATH \ -runsvdir -P <%= install_dir %>/service 'log: <%= '.'*395 %>' diff --git a/omnibus/cookbooks/firezone/.delivery/project.toml b/omnibus/cookbooks/firezone/.delivery/project.toml deleted file mode 100644 index 3a12ab52d..000000000 --- a/omnibus/cookbooks/firezone/.delivery/project.toml +++ /dev/null @@ -1,32 +0,0 @@ -# Delivery for Local Phases Execution -# -# This file allows you to execute test phases locally on a workstation or -# in a CI pipeline. The delivery-cli will read this file and execute the -# command(s) that are configured for each phase. You can customize them -# by just modifying the phase key on this file. -# -# By default these phases are configured for Cookbook Workflow only -# - -[local_phases] -unit = "echo skipping unit phase." -lint = "chef exec cookstyle" -# foodcritic has been deprecated in favor of cookstyle so we skip the syntax -# phase now. -syntax = "echo skipping syntax phase. Use lint phase instead." -provision = "chef exec kitchen create" -deploy = "chef exec kitchen converge" -smoke = "chef exec kitchen verify" -# The functional phase is optional, you can define it by uncommenting -# the line below and running the command: `delivery local functional` -# functional = "" -cleanup = "chef exec kitchen destroy" - -# Remote project.toml file -# -# Instead of the local phases above, you may specify a remote URI location for -# the `project.toml` file. This is useful for teams that wish to centrally -# manage the behavior of the `delivery local` command across many different -# projects. -# -# remote_file = "https://url/project.toml" diff --git a/omnibus/cookbooks/firezone/.gitignore b/omnibus/cookbooks/firezone/.gitignore deleted file mode 100644 index 875fbbac7..000000000 --- a/omnibus/cookbooks/firezone/.gitignore +++ /dev/null @@ -1,24 +0,0 @@ -.vagrant -*~ -*# -.#* -\#*# -.*.sw[a-z] -*.un~ - -# Bundler -Gemfile.lock -gems.locked -bin/* -.bundle/* - -# test kitchen -.kitchen/ -kitchen.local.yml - -# Chef Infra -Berksfile.lock -.zero-knife.rb -Policyfile.lock.json - -.idea/ diff --git a/omnibus/cookbooks/firezone/Berksfile b/omnibus/cookbooks/firezone/Berksfile deleted file mode 100644 index 69c44c3c6..000000000 --- a/omnibus/cookbooks/firezone/Berksfile +++ /dev/null @@ -1,8 +0,0 @@ -# frozen_string_literal: true - -source 'https://supermarket.chef.io' - -metadata - -cookbook 'enterprise' -cookbook 'fipsify' diff --git a/omnibus/cookbooks/firezone/CHANGELOG.md b/omnibus/cookbooks/firezone/CHANGELOG.md deleted file mode 100644 index 281cd069c..000000000 --- a/omnibus/cookbooks/firezone/CHANGELOG.md +++ /dev/null @@ -1,10 +0,0 @@ -# firezone CHANGELOG - -This file is used to list changes made in each version of the firezone cookbook. - -## 0.1.0 - -Initial release. - -- change 0 -- change 1 diff --git a/omnibus/cookbooks/firezone/Gemfile b/omnibus/cookbooks/firezone/Gemfile deleted file mode 100644 index aaf80a0d1..000000000 --- a/omnibus/cookbooks/firezone/Gemfile +++ /dev/null @@ -1,7 +0,0 @@ -# frozen_string_literal: true - -source 'https://rubygems.org' - -gem 'berkshelf' -gem 'chef', '~> 17.10.0' -gem 'chef-bin', '~> 17.10.0' diff --git a/omnibus/cookbooks/firezone/LICENSE b/omnibus/cookbooks/firezone/LICENSE deleted file mode 100644 index 33e138364..000000000 --- a/omnibus/cookbooks/firezone/LICENSE +++ /dev/null @@ -1,201 +0,0 @@ - Apache License - Version 2.0, January 2004 - http://www.apache.org/licenses/ - - TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION - - 1. Definitions. - - "License" shall mean the terms and conditions for use, reproduction, - and distribution as defined by Sections 1 through 9 of this document. - - "Licensor" shall mean the copyright owner or entity authorized by - the copyright owner that is granting the License. - - "Legal Entity" shall mean the union of the acting entity and all - other entities that control, are controlled by, or are under common - control with that entity. For the purposes of this definition, - "control" means (i) the power, direct or indirect, to cause the - direction or management of such entity, whether by contract or - otherwise, or (ii) ownership of fifty percent (50%) or more of the - outstanding shares, or (iii) beneficial ownership of such entity. - - "You" (or "Your") shall mean an individual or Legal Entity - exercising permissions granted by this License. - - "Source" form shall mean the preferred form for making modifications, - including but not limited to software source code, documentation - source, and configuration files. - - "Object" form shall mean any form resulting from mechanical - transformation or translation of a Source form, including but - not limited to compiled object code, generated documentation, - and conversions to other media types. - - "Work" shall mean the work of authorship, whether in Source or - Object form, made available under the License, as indicated by a - copyright notice that is included in or attached to the work - (an example is provided in the Appendix below). - - "Derivative Works" shall mean any work, whether in Source or Object - form, that is based on (or derived from) the Work and for which the - editorial revisions, annotations, elaborations, or other modifications - represent, as a whole, an original work of authorship. For the purposes - of this License, Derivative Works shall not include works that remain - separable from, or merely link (or bind by name) to the interfaces of, - the Work and Derivative Works thereof. - - "Contribution" shall mean any work of authorship, including - the original version of the Work and any modifications or additions - to that Work or Derivative Works thereof, that is intentionally - submitted to Licensor for inclusion in the Work by the copyright owner - or by an individual or Legal Entity authorized to submit on behalf of - the copyright owner. For the purposes of this definition, "submitted" - means any form of electronic, verbal, or written communication sent - to the Licensor or its representatives, including but not limited to - communication on electronic mailing lists, source code control systems, - and issue tracking systems that are managed by, or on behalf of, the - Licensor for the purpose of discussing and improving the Work, but - excluding communication that is conspicuously marked or otherwise - designated in writing by the copyright owner as "Not a Contribution." - - "Contributor" shall mean Licensor and any individual or Legal Entity - on behalf of whom a Contribution has been received by Licensor and - subsequently incorporated within the Work. - - 2. Grant of Copyright License. Subject to the terms and conditions of - this License, each Contributor hereby grants to You a perpetual, - worldwide, non-exclusive, no-charge, royalty-free, irrevocable - copyright license to reproduce, prepare Derivative Works of, - publicly display, publicly perform, sublicense, and distribute the - Work and such Derivative Works in Source or Object form. - - 3. Grant of Patent License. Subject to the terms and conditions of - this License, each Contributor hereby grants to You a perpetual, - worldwide, non-exclusive, no-charge, royalty-free, irrevocable - (except as stated in this section) patent license to make, have made, - use, offer to sell, sell, import, and otherwise transfer the Work, - where such license applies only to those patent claims licensable - by such Contributor that are necessarily infringed by their - Contribution(s) alone or by combination of their Contribution(s) - with the Work to which such Contribution(s) was submitted. If You - institute patent litigation against any entity (including a - cross-claim or counterclaim in a lawsuit) alleging that the Work - or a Contribution incorporated within the Work constitutes direct - or contributory patent infringement, then any patent licenses - granted to You under this License for that Work shall terminate - as of the date such litigation is filed. - - 4. Redistribution. You may reproduce and distribute copies of the - Work or Derivative Works thereof in any medium, with or without - modifications, and in Source or Object form, provided that You - meet the following conditions: - - (a) You must give any other recipients of the Work or - Derivative Works a copy of this License; and - - (b) You must cause any modified files to carry prominent notices - stating that You changed the files; and - - (c) You must retain, in the Source form of any Derivative Works - that You distribute, all copyright, patent, trademark, and - attribution notices from the Source form of the Work, - excluding those notices that do not pertain to any part of - the Derivative Works; and - - (d) If the Work includes a "NOTICE" text file as part of its - distribution, then any Derivative Works that You distribute must - include a readable copy of the attribution notices contained - within such NOTICE file, excluding those notices that do not - pertain to any part of the Derivative Works, in at least one - of the following places: within a NOTICE text file distributed - as part of the Derivative Works; within the Source form or - documentation, if provided along with the Derivative Works; or, - within a display generated by the Derivative Works, if and - wherever such third-party notices normally appear. The contents - of the NOTICE file are for informational purposes only and - do not modify the License. You may add Your own attribution - notices within Derivative Works that You distribute, alongside - or as an addendum to the NOTICE text from the Work, provided - that such additional attribution notices cannot be construed - as modifying the License. - - You may add Your own copyright statement to Your modifications and - may provide additional or different license terms and conditions - for use, reproduction, or distribution of Your modifications, or - for any such Derivative Works as a whole, provided Your use, - reproduction, and distribution of the Work otherwise complies with - the conditions stated in this License. - - 5. Submission of Contributions. Unless You explicitly state otherwise, - any Contribution intentionally submitted for inclusion in the Work - by You to the Licensor shall be under the terms and conditions of - this License, without any additional terms or conditions. - Notwithstanding the above, nothing herein shall supersede or modify - the terms of any separate license agreement you may have executed - with Licensor regarding such Contributions. - - 6. Trademarks. This License does not grant permission to use the trade - names, trademarks, service marks, or product names of the Licensor, - except as required for reasonable and customary use in describing the - origin of the Work and reproducing the content of the NOTICE file. - - 7. Disclaimer of Warranty. Unless required by applicable law or - agreed to in writing, Licensor provides the Work (and each - Contributor provides its Contributions) on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or - implied, including, without limitation, any warranties or conditions - of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A - PARTICULAR PURPOSE. You are solely responsible for determining the - appropriateness of using or redistributing the Work and assume any - risks associated with Your exercise of permissions under this License. - - 8. Limitation of Liability. In no event and under no legal theory, - whether in tort (including negligence), contract, or otherwise, - unless required by applicable law (such as deliberate and grossly - negligent acts) or agreed to in writing, shall any Contributor be - liable to You for damages, including any direct, indirect, special, - incidental, or consequential damages of any character arising as a - result of this License or out of the use or inability to use the - Work (including but not limited to damages for loss of goodwill, - work stoppage, computer failure or malfunction, or any and all - other commercial damages or losses), even if such Contributor - has been advised of the possibility of such damages. - - 9. Accepting Warranty or Additional Liability. While redistributing - the Work or Derivative Works thereof, You may choose to offer, - and charge a fee for, acceptance of support, warranty, indemnity, - or other liability obligations and/or rights consistent with this - License. However, in accepting such obligations, You may act only - on Your own behalf and on Your sole responsibility, not on behalf - of any other Contributor, and only if You agree to indemnify, - defend, and hold each Contributor harmless for any liability - incurred by, or claims asserted against, such Contributor by reason - of your accepting any such warranty or additional liability. - - END OF TERMS AND CONDITIONS - - APPENDIX: How to apply the Apache License to your work. - - To apply the Apache License to your work, attach the following - boilerplate notice, with the fields enclosed by brackets "{}" - replaced with your own identifying information. (Don't include - the brackets!) The text should be enclosed in the appropriate - comment syntax for the file format. We also recommend that a - file or class name and description of purpose be included on the - same "printed page" as the copyright notice for easier - identification within third-party archives. - - Copyright 2020 Engineering - - Licensed under the Apache License, Version 2.0 (the "License"); - you may not use this file except in compliance with the License. - You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - - Unless required by applicable law or agreed to in writing, software - distributed under the License is distributed on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - See the License for the specific language governing permissions and - limitations under the License. diff --git a/omnibus/cookbooks/firezone/Policyfile.rb b/omnibus/cookbooks/firezone/Policyfile.rb deleted file mode 100644 index 726312eec..000000000 --- a/omnibus/cookbooks/firezone/Policyfile.rb +++ /dev/null @@ -1,20 +0,0 @@ -# rubocop:disable Naming/FileName -# frozen_string_literal: true - -# Policyfile.rb - Describe how you want Chef Infra Client to build your system. -# -# For more information on the Policyfile feature, visit -# https://docs.chef.io/policyfile/ - -# A name that describes what the system you're building with Chef does. -name 'firezone' - -# Where to find external cookbooks: -default_source :supermarket - -# run_list: chef-client will run these recipes in the order specified. -run_list 'firezone::default' - -# Specify a custom source for a single cookbook: -cookbook 'firezone', path: '.' -# rubocop:enable Naming/FileName diff --git a/omnibus/cookbooks/firezone/README.md b/omnibus/cookbooks/firezone/README.md deleted file mode 100644 index 8fb35ef5b..000000000 --- a/omnibus/cookbooks/firezone/README.md +++ /dev/null @@ -1,3 +0,0 @@ -# firezone - -TODO: Enter the cookbook description here. diff --git a/omnibus/cookbooks/firezone/attributes/default.rb b/omnibus/cookbooks/firezone/attributes/default.rb deleted file mode 100644 index c1e2d678b..000000000 --- a/omnibus/cookbooks/firezone/attributes/default.rb +++ /dev/null @@ -1,590 +0,0 @@ -# frozen_string_literal: true - -# # Firezone configuration - -require 'etc' - -# -# Attributes here will be applied to configure the application and the services -# it uses. -# -# Most of the attributes in this file are things you will not need to ever -# touch, but they are here in case you need them. -# -# A `firezone-ctl reconfigure` should pick up any changes made here. -# -# If /etc/firezone/firezone.json exists, its attributes will be loaded -# after these, so if you have that file with the contents: -# -# { "postgresql": { "enable": false } } -# -# for example, it will set the node['firezone']['postgresql']['enabled'] attribute to false. - -# ## Top-level attributes -# -# These are used by the other items below. More app-specific top-level -# attributes are further down in this file. - -# ## External URL (REQUIRED) -# -# This will be used to generate URLs for outbound emails, websocket connections -# and OAuth redirects. -# and host headers that nginx passes along. If using a custom path, scheme, or port, -# you may want to change this, e.g. http://firezone.example.com:1234/custom-root-prefix/ -default['firezone']['external_url'] = "https://#{node['fqdn'] || node['hostname']}" - -# Email for the primary admin user. -default['firezone']['admin_email'] = 'firezone@localhost' - -# The maximum number of devices a user can have. -# Max: 100 -# Default: 10 -default['firezone']['max_devices_per_user'] = 10 - -# Allow users to create (and download) their own devices. Set to false -# if you only want administrators to create and manage devices. -default['firezone']['allow_unprivileged_device_management'] = true - -# Allow users to configure the following device fields when creating a device: -# use_site_allowed_ips -# allowed_ips -# use_site_dns -# dns -# use_site_endpoint -# endpoint -# use_site_mtu -# mtu -# use_site_persistent_keepalive -# persistent_keepalive -# ipv4 -# ipv6 -# -# If you only want users to modify the name and description for new devices, -# disable this. -default['firezone']['allow_unprivileged_device_configuration'] = true - -default['firezone']['config_directory'] = '/etc/firezone' -default['firezone']['install_directory'] = '/opt/firezone' -default['firezone']['app_directory'] = "#{node['firezone']['install_directory']}/embedded/service/firezone" -default['firezone']['log_directory'] = '/var/log/firezone' -default['firezone']['var_directory'] = '/var/opt/firezone' -default['firezone']['user'] = 'firezone' -default['firezone']['group'] = 'firezone' - -# The outgoing interface name. -# This is where tunneled traffic will exit the WireGuard tunnel. -# If set to nil, this is will be set to the interface for the machine's -# default route. -default['firezone']['egress_interface'] = nil - -# Whether to use OpenSSL FIPS mode across Firezone. Default disabled. -default['firezone']['fips_enabled'] = nil - -# ## Global Logging Settings -# -# Enable or disable logging. Set this to false to disable Firezone logs. -default['firezone']['logging']['enabled'] = true - -# ## Enterprise -# -# The "enterprise" cookbook provides recipes and resources we can use for this -# app. - -default['enterprise']['name'] = 'firezone' - -# Enterprise uses install_path internally, but we use install_directory because -# it's more consistent. Alias it here so both work. -default['firezone']['install_path'] = node['firezone']['install_directory'] - -# An identifier used in /etc/inittab (default is 'SUP'). Needs to be a unique -# (for the file) sequence of 1-4 characters. -default['firezone']['sysvinit_id'] = 'SUP' - -# ## Authentication - -# These settings control authentication-related aspects of Firezone. -# For more information, see https://docs.firezone.dev/user-guides/authentication/ -# -# When local email/password authentication is used, users must be created by an Administrator -# before they can sign in. -# -# When SSO authentication methods are used, users are automatically added to Firezone -# when logging in for the first time via the SSO provider. -# -# Users are uniquely identified by their email address, and may sign in via multiple providers -# if configured. - -# Local email/password authentication is enabled by default -default['firezone']['authentication']['local']['enabled'] = true - -# OIDC Authentication -# -# Firezone can disable a user's VPN if there's any error detected trying - # to refresh their access_token. This is verified to work for Google, Okta, and - # Azure SSO and is used to automatically disconnect a user's VPN if they're removed - # from the OIDC provider. Leave this disabled if your OIDC provider - # has issues refreshing access tokens as it could unexpectedly interrupt a - # user's VPN session. -default['firezone']['authentication']['disable_vpn_on_oidc_error'] = false - -# Any OpenID Connect provider can be used here. -# Multiple OIDC configs can be added to the same Firezone instance. -# This is an example using Google and Okta as an SSO identity provider. -# default['firezone']['authentication']['oidc'] = [ -# { -# discovery_document_uri: "https://accounts.google.com/.well-known/openid-configuration", -# client_id: "", -# client_secret: "", -# redirect_uri: "https://firezone.example.com/auth/oidc/google/callback/", -# response_type: "code", -# scope: "openid email profile", -# label: "Google", -# auto_create_users: true -# }, -# okta: { -# discovery_document_uri: "https:///.well-known/openid-configuration", -# client_id: "", -# client_secret: "", -# redirect_uri: "https://firezone.example.com/auth/oidc/okta/callback/", -# response_type: "code", -# scope: "openid email profile offline_access", -# label: "Okta", -# auto_create_users: true -# } -# ] -default['firezone']['authentication']['oidc'] = [] - -# SAML Authentication providers -# -# Example adding an OKTA provider: -# -# default['firezone']['authentication']['saml'] = [ -# { -# "auto_create_users": false, -# "base_url": "https://saml", -# "id": "okta", -# "label": "okta", -# "metadata": "...", -# "sign_metadata": false, -# "sign_requests": false, -# "signed_assertion_in_resp": false, -# "signed_envelopes_in_resp": false -# } -# ] -default['firezone']['authentication']['saml'] = [] - -# ## Custom Reverse Proxy -# -# An array of IPs that Firezone will trust as reverse proxies. -# -# Read more here: -# https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/X-Forwarded-For#selecting_an_ip_address -# -# By default the following IPs are included: -# * IPv4: 127.0.0.0/8, 10.0.0.0/8, 172.16.0.0/12, 192.168.0.0/16 -# * IPv6: ::1/128, fc00::/7 -# -# If any client requests will actually be coming from these private IPs, add them to -# default['firezone']['phoenix']['private_clients'] below instead of here. -# -# If set to false Firezone will assume that it is not running behind a proxy -default['firezone']['phoenix']['external_trusted_proxies'] = [] - -# An array of IPs that Firezone will assume are clients, and thus, not a trusted -# proxy for the purpose of determining the client's IP. By default the bundled -# See more here: https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/X-Forwarded-For#selecting_an_ip_address -# This will supersede any proxy configured manually or by default by -# default['firezone']['external_trusted_proxies'] -default['firezone']['phoenix']['private_clients'] = [] - -# ## Nginx - -# These attributes control Firezone-specific portions of the Nginx -# configuration and the virtual host for the Firezone Phoenix app. -default['firezone']['nginx']['enabled'] = true -default['firezone']['nginx']['ssl_port'] = 443 -default['firezone']['nginx']['directory'] = "#{node['firezone']['var_directory']}/nginx/etc" -default['firezone']['nginx']['log_directory'] = "#{node['firezone']['log_directory']}/nginx" -default['firezone']['nginx']['log_rotation']['file_maxbytes'] = 104_857_600 -default['firezone']['nginx']['log_rotation']['num_to_keep'] = 10 -default['firezone']['nginx']['log_x_forwarded_for'] = true - -# HSTS Header settings -default['firezone']['nginx']['hsts_header']['enabled'] = true -default['firezone']['nginx']['hsts_header']['include_subdomains'] = true -default['firezone']['nginx']['hsts_header']['max_age'] = 31536000 - -# Permit nginx to listen for IPv6 connections in addition to IPv4 -default['firezone']['nginx']['ipv6'] = true - -# Redirect to the FQDN -default['firezone']['nginx']['redirect_to_canonical'] = false - -# Controls nginx caching, used to cache some endpoints -default['firezone']['nginx']['cache']['enabled'] = false -default['firezone']['nginx']['cache']['directory'] = "#{node['firezone']['var_directory']}/nginx/cache" - -# These attributes control the main nginx.conf, including the events and http -# contexts. -# -# These will be copied to the top-level nginx namespace and used in a -# template from the community nginx cookbook -# (https://github.com/miketheman/nginx/blob/master/templates/default/nginx.conf.erb) -default['firezone']['nginx']['user'] = node['firezone']['user'] -default['firezone']['nginx']['group'] = node['firezone']['group'] -default['firezone']['nginx']['dir'] = node['firezone']['nginx']['directory'] -default['firezone']['nginx']['log_dir'] = node['firezone']['nginx']['log_directory'] -default['firezone']['nginx']['pid'] = "#{node['firezone']['nginx']['directory']}/nginx.pid" -default['firezone']['nginx']['daemon_disable'] = true -default['firezone']['nginx']['gzip'] = 'on' -default['firezone']['nginx']['gzip_static'] = 'off' -default['firezone']['nginx']['gzip_http_version'] = '1.0' -default['firezone']['nginx']['gzip_comp_level'] = '2' -default['firezone']['nginx']['gzip_proxied'] = 'any' -default['firezone']['nginx']['gzip_vary'] = 'off' -default['firezone']['nginx']['gzip_buffers'] = nil -default['firezone']['nginx']['gzip_types'] = %w[ - text/plain - text/css - application/x-javascript - text/xml - application/xml - application/rss+xml - application/atom+xml - text/javascript - application/javascript - application/json -] -default['firezone']['nginx']['gzip_min_length'] = 1000 -default['firezone']['nginx']['gzip_disable'] = 'MSIE [1-6]\.' -default['firezone']['nginx']['keepalive'] = 'on' -default['firezone']['nginx']['keepalive_timeout'] = 65 -default['firezone']['nginx']['worker_processes'] = node['cpu'] && node['cpu']['total'] ? node['cpu']['total'] : 1 -default['firezone']['nginx']['worker_connections'] = 1024 -default['firezone']['nginx']['worker_rlimit_nofile'] = nil -default['firezone']['nginx']['multi_accept'] = true -default['firezone']['nginx']['event'] = 'epoll' -default['firezone']['nginx']['server_tokens'] = nil -default['firezone']['nginx']['server_names_hash_bucket_size'] = 64 -default['firezone']['nginx']['sendfile'] = 'on' -default['firezone']['nginx']['access_log_options'] = nil -default['firezone']['nginx']['error_log_options'] = nil -default['firezone']['nginx']['disable_access_log'] = false -default['firezone']['nginx']['types_hash_max_size'] = 2048 -default['firezone']['nginx']['types_hash_bucket_size'] = 64 -default['firezone']['nginx']['proxy_read_timeout'] = nil -default['firezone']['nginx']['client_body_buffer_size'] = nil -default['firezone']['nginx']['client_max_body_size'] = '250m' -default['firezone']['nginx']['default']['modules'] = [] - -# Nginx rate limiting configuration. -# Note that requests are also rate limited by the upstream Phoenix application. -default['firezone']['nginx']['enable_rate_limiting'] = true -default['firezone']['nginx']['rate_limiting_zone_name'] = 'firezone' -default['firezone']['nginx']['rate_limiting_backoff'] = '10m' -default['firezone']['nginx']['rate_limit'] = '10r/s' - -# ## Postgres - -# ### Use the bundled Postgres instance (default, recommended): -# - -default['firezone']['postgresql']['enabled'] = true -default['firezone']['postgresql']['username'] = node['firezone']['user'] -default['firezone']['postgresql']['data_directory'] = "#{node['firezone']['var_directory']}/postgresql/13.3/data" - -# ### Using an external Postgres database -# -# Disable the provided Postgres instance and connect to your own: -# -# default['firezone']['postgresql']['enabled'] = false -# default['firezone']['database']['user'] = 'my_db_user_name' -# default['firezone']['database']['name'] = 'my_db_name'' -# default['firezone']['database']['host'] = 'my.db.server.address' -# default['firezone']['database']['port'] = 5432 -# -# Further database configuration options can be found below - -# ### Logs -default['firezone']['postgresql']['log_directory'] = "#{node['firezone']['log_directory']}/postgresql" -default['firezone']['postgresql']['log_rotation']['file_maxbytes'] = 104_857_600 -default['firezone']['postgresql']['log_rotation']['num_to_keep'] = 10 - -# ### Postgres Settings -default['firezone']['postgresql']['checkpoint_completion_target'] = 0.5 -default['firezone']['postgresql']['checkpoint_segments'] = 3 -default['firezone']['postgresql']['checkpoint_timeout'] = '5min' -default['firezone']['postgresql']['checkpoint_warning'] = '30s' -default['firezone']['postgresql']['effective_cache_size'] = '128MB' -default['firezone']['postgresql']['listen_address'] = '127.0.0.1' -default['firezone']['postgresql']['max_connections'] = 350 -default['firezone']['postgresql']['md5_auth_cidr_addresses'] = ['127.0.0.1/32', '::1/128'] -default['firezone']['postgresql']['port'] = 15_432 -default['firezone']['postgresql']['shared_buffers'] = "#{(node['memory']['total'].to_i / 4) / 1024}MB" -default['firezone']['postgresql']['shmmax'] = 17_179_869_184 -default['firezone']['postgresql']['shmall'] = 4_194_304 -default['firezone']['postgresql']['work_mem'] = '8MB' - -# ## Common Database Settings -# -# The settings below configure how Firezone connects to and uses your database. -# At this time only Postgres (and Postgres-compatible) databases are supported. -default['firezone']['database']['user'] = node['firezone']['postgresql']['username'] -default['firezone']['database']['name'] = 'firezone' -default['firezone']['database']['host'] = node['firezone']['postgresql']['listen_address'] -default['firezone']['database']['port'] = node['firezone']['postgresql']['port'] -default['firezone']['database']['ssl'] = false - -# SSL opts to pass to Erlang's SSL module. See a full listing at https://www.erlang.org/doc/man/ssl.html -# Firezone supports the following subset: -# { -# verify: :verify_peer, # or :verify_none -# cacerts: "...", # The DER-encoded trusted certificates. Overrides :cacertfile if specified. -# cacertfile: "/path/to/cert.pem", # Path to a file containing PEM-encoded CA certificates. -# versions: ["tlsv1.1", "tlsv1.2", "tlsv1.3"], # Array of TLS versions to enable -# } -default['firezone']['database']['ssl_opts'] = {} - -# DB Connection Parameters to pass to the Postgrex driver. If you're unsure, leave this blank. -default['firezone']['database']['parameters'] = {} - -default['firezone']['database']['pool'] = [10, Etc.nprocessors].max -default['firezone']['database']['extensions'] = { 'plpgsql' => true, 'pg_trgm' => true } - -# Create the DB user. Set this to false if the user already exists. -default['firezone']['database']['create_user'] = true - -# Create the DB. Set this to false if the database already exists. -default['firezone']['database']['create_db'] = true - -# Uncomment to specify a database password. Not usually needed if using the bundled Postgresql. -# default['firezone']['database']['password'] = 'change_me' - -# ## Phoenix - -# ### The Phoenix web app for Firezone -default['firezone']['phoenix']['enabled'] = true -default['firezone']['phoenix']['listen_address'] = '127.0.0.1' -default['firezone']['phoenix']['port'] = 13_000 -default['firezone']['phoenix']['log_directory'] = "#{node['firezone']['log_directory']}/phoenix" -default['firezone']['phoenix']['log_rotation']['file_maxbytes'] = 104_857_600 -default['firezone']['phoenix']['log_rotation']['num_to_keep'] = 10 - -# Toggle bringing down the web app for Firezone if a crash loop is detected. -# When set to true, the web app will be brought down after 5 crashes. -# When set to false, this will allow the web app to crash indefinitely. -default['firezone']['phoenix']['crash_detection']['enabled'] = true - -# ## WireGuard - -# ### Interface Management -# Enable management of the WireGuard interface itself. Set this to false if you -# want to manually create your WireGuard interface and manage its interface properties. -default['firezone']['wireguard']['enabled'] = true -default['firezone']['wireguard']['log_directory'] = "#{node['firezone']['log_directory']}/wireguard" -default['firezone']['wireguard']['log_rotation']['file_maxbytes'] = 104_857_600 -default['firezone']['wireguard']['log_rotation']['num_to_keep'] = 10 - -# The WireGuard interface name Firezone will apply configuration settings to. -default['firezone']['wireguard']['interface_name'] = 'wg-firezone' - -# WireGuard listen port -default['firezone']['wireguard']['port'] = 51_820 - -# WireGuard interface MTU -default['firezone']['wireguard']['mtu'] = 1280 - -# WireGuard endpoint -# By default, the public IP address of this server is used as the Endpoint -# field for generating Device configs. Override this if you wish to change. -default['firezone']['wireguard']['endpoint'] = nil - -# Default AllowedIPs to use for generated device configs specified as a comma-separated -# list of IPv4 / IPv6 CIDRs. -# Default is to tunnel all IPv4 and IPv6 traffic with '0.0.0.0/0, ::/0' -default['firezone']['wireguard']['allowed_ips'] = '0.0.0.0/0, ::/0' - -# Default DNS servers to use for generated device configs. -# Defaults to CloudFlare's public DNS. Set to nil to omit DNS from generated -# device configurations. -default['firezone']['wireguard']['dns'] = '1.1.1.1, 1.0.0.1' - -# Default PersistentKeepalive setting to use for generated device configs. -# See https://www.wireguard.com/quickstart/#nat-and-firewall-traversal-persistence -# Set to 0 or nil to disable. Default 0. -default['firezone']['wireguard']['persistent_keepalive'] = 0 - -# Enable or disable IPv4 connectivity in your WireGuard network. Default enabled. -default['firezone']['wireguard']['ipv4']['enabled'] = true - -# Enable or disable SNAT/Masquerade for packets leaving the WireGuard ipv4 tunnel. Default true. -default['firezone']['wireguard']['ipv4']['masquerade'] = true - -# The CIDR-formatted IPv4 network to use for your WireGuard network. Default 10.3.2.0/24. -default['firezone']['wireguard']['ipv4']['network'] = '10.3.2.0/24' - -# The IPv4 address to assign to your WireGuard interface. Must be an address -# contained within the WireGuard network specific above. Default 10.3.2.1. -default['firezone']['wireguard']['ipv4']['address'] = '10.3.2.1' - -# Enable or disable IPv6 connectivity in your WireGuard network. Default enabled. -default['firezone']['wireguard']['ipv6']['enabled'] = true - -# Enable or disable SNAT/Masquerade for packets leaving the WireGuard ipv6 tunnel. Default true. -default['firezone']['wireguard']['ipv6']['masquerade'] = true - -# The CIDR-formatted IPv6 network to use for your WireGuard network. Default fd00::3:2:0/120. -default['firezone']['wireguard']['ipv6']['network'] = 'fd00::3:2:0/120' - -# The IPv6 address to assign to your WireGuard interface. Must be an address -# contained within the WireGuard network specific above. Default fd00::3:2:1. -default['firezone']['wireguard']['ipv6']['address'] = 'fd00::3:2:1' - -# ## Runit - -# This is missing from the enterprise cookbook -# see (https://github.com/chef-cookbooks/enterprise-chef-common/pull/17) -# -# Will be copied to the root node.runit namespace. -default['firezone']['runit']['svlogd_bin'] = "#{node['firezone']['install_directory']}/embedded/bin/svlogd" - -# ## SSL - -default['firezone']['ssl']['directory'] = '/var/opt/firezone/ssl' - -# Email to use for self signed certs and ACME cert issuance and renewal notices. -# Defaults to default['firezone']['admin_email'] if nil. -default['firezone']['ssl']['email_address'] = nil - -# Enable / disable ACME protocol support to auto-provision SSL certificates. -# Before turning this on, please ensure: -# 1. default['firezone']['external_url'] includes a valid FQDN -# 2. Port 80/tcp is accessible; this is used for domain validation. -# 3. default['firezone']['ssl']['email_address'] is set properly. This will be used for renewal notices. -default['firezone']['ssl']['acme']['enabled'] = false - -# Set the ACME server directory for ACME protocol SSL certificate issuance -# This option requires default['firezone']['ssl']['acme']['enabled'] -# You can either set one of the CA short names as explained here (https://github.com/acmesh-official/acme.sh/wiki/Server) -# or the directory URL. -# In case ACME is enabled this option will default to letsencrypt -default['firezone']['ssl']['acme']['server'] = 'letsencrypt' -# Specify the key type and length for the cert. See more at https://github.com/acmesh-official/acme.sh#10-issue-ecc-certificates -# Allowed values are: -# * RSA: 2048, 3072, 4096, 8192 -# * ECDSA(recommended): ec-256, ec-384, ec-521 -default['firezone']['ssl']['acme']['keylength'] = 'ec-256' - - -# Paths to the SSL certificate and key files. If these are set, ACME is automatically disabled. -# If these are nil and ACME is disabled, we will attempt to generate a self-signed certificate and use that instead. -default['firezone']['ssl']['certificate'] = nil -default['firezone']['ssl']['certificate_key'] = nil - -# Path to the SSL dhparam file if you want to specify your own SSL DH parameters. -default['firezone']['ssl']['ssl_dhparam'] = nil - -# These are used in creating a self-signed cert if you haven't brought your own. -default['firezone']['ssl']['country_name'] = 'US' -default['firezone']['ssl']['state_name'] = 'CA' -default['firezone']['ssl']['locality_name'] = 'San Francisco' -default['firezone']['ssl']['company_name'] = 'My Company' -default['firezone']['ssl']['organizational_unit_name'] = 'Operations' - -# ### Cipher settings -# -# Based off of the Mozilla recommended cipher suite -# https://wiki.mozilla.org/Security/Server_Side_TLS#Recommended_Ciphersuite -# -# SSLV3 was removed because of the poodle attack. (https://www.openssl.org/~bodo/ssl-poodle.pdf) -# -# If your infrastructure still has requirements for the vulnerable/venerable SSLV3, you can add -# "SSLv3" to the below line. -default['firezone']['ssl']['ciphers'] = - 'ECDHE-RSA-AES128-GCM-SHA256:ECDHE-ECDSA-AES128-GCM-SHA256:ECDHE-RSA-AES256-GCM-SHA384:ECDHE-ECDSA-AES256-GCM-SHA384:DHE-RSA-AES128-GCM-SHA256:DHE-DSS-AES128-GCM-SHA256:kEDH+AESGCM:ECDHE-RSA-AES128-SHA256:ECDHE-ECDSA-AES128-SHA256:ECDHE-RSA-AES128-SHA:ECDHE-ECDSA-AES128-SHA:ECDHE-RSA-AES256-SHA384:ECDHE-ECDSA-AES256-SHA384:ECDHE-RSA-AES256-SHA:ECDHE-ECDSA-AES256-SHA:DHE-RSA-AES128-SHA256:DHE-RSA-AES128-SHA:DHE-DSS-AES128-SHA256:DHE-RSA-AES256-SHA256:DHE-DSS-AES256-SHA:DHE-RSA-AES256-SHA:AES128-GCM-SHA256:AES256-GCM-SHA384:AES128-SHA:AES256-SHA:AES:CAMELLIA:DES-CBC3-SHA:!aNULL:!eNULL:!EXPORT:!DES:!RC4:!MD5:!PSK:!aECDH:!EDH-DSS-DES-CBC3-SHA:!EDH-RSA-DES-CBC3-SHA:!KRB5-DES-CBC3-SHA' -default['firezone']['ssl']['fips_ciphers'] = 'FIPS@STRENGTH:!aNULL:!eNULL' -default['firezone']['ssl']['protocols'] = 'TLSv1 TLSv1.1 TLSv1.2' -default['firezone']['ssl']['session_cache'] = 'shared:SSL:4m' -default['firezone']['ssl']['session_timeout'] = '5m' - -# ### robots.txt Settings -# -# These control the "Allow" and "Disallow" paths in /robots.txt. See -# http://www.robotstxt.org/robotstxt.html for more information. Only a single -# line for each item is supported. If a value is nil, the line will not be -# present in the file. -default['firezone']['robots_allow'] = '/' -default['firezone']['robots_disallow'] = nil - -# ### Outbound Email Settings -# If from_email not set, the outbound email feature will be disabled (default) -default['firezone']['outbound_email']['from'] = nil - -# If provider not set, the :sendmail delivery method will be used. Using -# the sendmail delivery method requires that a working mail transfer agent -# (usually set up with a relay host) be configured on this machine. -default['firezone']['outbound_email']['provider'] = nil - -# Configure one or more providers below. -# See the Swoosh library documentation for more information on configuring adapters: -# https://github.com/swoosh/swoosh#adapters -default['firezone']['outbound_email']['configs'] = { - smtp: { - # only relay is required, but you will need some combination of the rest - relay: 'smtp.example.com', - port: 587, # integer - username: '', # needs to be string if present - password: '', # needs to be string if present - ssl: true, # boolean - tls: :always, # always / never / if_available - auth: :always, # always / never / if_available - no_mx_lookup: false, # boolean - retries: 2 # integer - }, - mailgun: { - # both are required - apikey: nil, - domain: nil # example.com - }, - mandrill: { - api_key: nil - }, - sendgrid: { - api_key: nil - }, - post_mark: { - api_key: nil - }, - sendmail: { - cmd_path: '/usr/bin/sendmail', - cmd_args: '-N delay,failure,success' - } -} - -# ## Telemetry -# -# Firezone relies heavily on hashed, anonymized telemetry data to help us build -# a better product for our users. This data is stored securely and is not -# shared or accessible to any third parties. Set this to false to disable. -default['firezone']['telemetry']['enabled'] = true - -# ## Diagnostics Settings - -# ### Connectivity Checks -# -# By default, Firezone periodically checks for WAN connectivity to the Internet -# by issuing a POST request with an empty body to https://ping.firez.one. This -# is used to determine the server's publicly routable IP address for populating -# device configurations and setting up firewall rules. Set this to false to -# disable. -default['firezone']['connectivity_checks']['enabled'] = true - -# Amount of time to sleep between connectivity checks, in seconds. -# Default: 3600 (1 hour). Minimum: 60 (1 minute). Maximum: 86400 (1 day). -default['firezone']['connectivity_checks']['interval'] = 3_600 - -# ## Cookies settings - -# Enable or disable the secure attributes for Firezone cookies. It's highly -# recommended you leave this enabled unless you know what you're doing. -default['firezone']['phoenix']['secure_cookies'] = true diff --git a/omnibus/cookbooks/firezone/chefignore b/omnibus/cookbooks/firezone/chefignore deleted file mode 100644 index cc170ea79..000000000 --- a/omnibus/cookbooks/firezone/chefignore +++ /dev/null @@ -1,115 +0,0 @@ -# Put files/directories that should be ignored in this file when uploading -# to a Chef Infra Server or Supermarket. -# Lines that start with '# ' are comments. - -# OS generated files # -###################### -.DS_Store -ehthumbs.db -Icon? -nohup.out -Thumbs.db -.envrc - -# EDITORS # -########### -.#* -.project -.settings -*_flymake -*_flymake.* -*.bak -*.sw[a-z] -*.tmproj -*~ -\#* -REVISION -TAGS* -tmtags -.vscode -.editorconfig - -## COMPILED ## -############## -*.class -*.com -*.dll -*.exe -*.o -*.pyc -*.so -*/rdoc/ -a.out -mkmf.log - -# Testing # -########### -.circleci/* -.codeclimate.yml -.delivery/* -.foodcritic -.kitchen* -.mdlrc -.overcommit.yml -.rspec -.rubocop.yml -.travis.yml -.watchr -.yamllint -azure-pipelines.yml -Dangerfile -examples/* -features/* -Guardfile -kitchen.yml* -mlc_config.json -Procfile -Rakefile -spec/* -test/* - -# SCM # -####### -.git -.gitattributes -.gitconfig -.github/* -.gitignore -.gitkeep -.gitmodules -.svn -*/.bzr/* -*/.git -*/.hg/* -*/.svn/* - -# Berkshelf # -############# -Berksfile -Berksfile.lock -cookbooks/* -tmp - -# Bundler # -########### -vendor/* -Gemfile -Gemfile.lock - -# Policyfile # -############## -Policyfile.rb -Policyfile.lock.json - -# Documentation # -############# -CODE_OF_CONDUCT* -CONTRIBUTING* -documentation/* -TESTING* -UPGRADING* - -# Vagrant # -########### -.vagrant -Vagrantfile diff --git a/omnibus/cookbooks/firezone/files/default/ctl-commands/create_admin.rb b/omnibus/cookbooks/firezone/files/default/ctl-commands/create_admin.rb deleted file mode 100644 index 24007e462..000000000 --- a/omnibus/cookbooks/firezone/files/default/ctl-commands/create_admin.rb +++ /dev/null @@ -1,51 +0,0 @@ -# frozen_string_literal: true - -require 'mixlib/shellout' -require 'uri' -require 'net/http' -require 'json' - -desc = <<~DESC - Resets the password for admin with email specified by default['firezone']['admin_email'] or creates a new admin if that email doesn't exist. -DESC - -# rubocop:disable Metrics/MethodLength -def capture - telemetry_file = '/var/opt/firezone/cache/telemetry_id' - return unless File.exist?(telemetry_file) - - telemetry_id = File.read(telemetry_file) - - return unless telemetry_id - - uri = URI('https://t.firez.one/capture/') - data = { - api_key: 'phc_ubuPhiqqjMdedpmbWpG2Ak3axqv5eMVhFDNBaXl9UZK', - event: 'firezone-ctl create-or-reset-admin', - properties: { - distinct_id: telemetry_id - } - } - return if File.exist?('/var/opt/firezone/.disable_telemetry') || ENV['TELEMETRY_ENABLED'] == 'false' - - Net::HTTP.post(uri, data.to_json, 'Content-Type' => 'application/json') -rescue StandardError => e - e -end -# rubocop:enable Metrics/MethodLength - -add_command_under_category 'create-or-reset-admin', 'general', desc, 2 do - command = %W( - chef-client - -z - -l info - -c #{base_path}/embedded/cookbooks/solo.rb - -o recipe[firezone::create_admin] - ) - - capture - - result = run_command(command.join(' ')) - remove_old_node_state - Kernel.exit 1 unless result.success? -end diff --git a/omnibus/cookbooks/firezone/files/default/ctl-commands/force_renewal.rb b/omnibus/cookbooks/firezone/files/default/ctl-commands/force_renewal.rb deleted file mode 100644 index 95e07a1e4..000000000 --- a/omnibus/cookbooks/firezone/files/default/ctl-commands/force_renewal.rb +++ /dev/null @@ -1,48 +0,0 @@ -# frozen_string_literal: true - -require 'mixlib/shellout' -require 'uri' -require 'net/http' -require 'json' - -# rubocop:disable Metrics/MethodLength -def capture - telemetry_file = '/var/opt/firezone/cache/telemetry_id' - return unless File.exist?(telemetry_file) - - telemetry_id = File.read(telemetry_file) - - return unless telemetry_id - - uri = URI('https://t.firez.one/capture/') - data = { - api_key: 'phc_ubuPhiqqjMdedpmbWpG2Ak3axqv5eMVhFDNBaXl9UZK', - event: 'firezone-ctl force-cert-renewal', - properties: { - distinct_id: telemetry_id - } - } - return if File.exist?('/var/opt/firezone/.disable_telemetry') || ENV['TELEMETRY_ENABLED'] == 'false' - - Net::HTTP.post(uri, data.to_json, 'Content-Type' => 'application/json') -rescue StandardError => e - e -end -# rubocop:enable Metrics/MethodLength - -add_command_under_category 'force-cert-renewal', 'general', 'Force certificate renewal now even if it hasn\'t expired.', - 2 do - command = %W( - chef-client - -z - -l info - -c #{base_path}/embedded/cookbooks/solo.rb - -o recipe[firezone::force_renewal] - ) - - capture - - result = run_command(command.join(' ')) - remove_old_node_state - Kernel.exit 1 unless result.success? -end diff --git a/omnibus/cookbooks/firezone/files/default/ctl-commands/reconfigure.rb b/omnibus/cookbooks/firezone/files/default/ctl-commands/reconfigure.rb deleted file mode 100644 index ce9048154..000000000 --- a/omnibus/cookbooks/firezone/files/default/ctl-commands/reconfigure.rb +++ /dev/null @@ -1,44 +0,0 @@ -# frozen_string_literal: true - -require 'mixlib/shellout' -require 'uri' -require 'net/http' -require 'json' - -# rubocop:disable Metrics/MethodLength -def capture - telemetry_file = '/var/opt/firezone/cache/telemetry_id' - return unless File.exist?(telemetry_file) - - telemetry_id = File.read(telemetry_file) - - return unless telemetry_id - - uri = URI('https://t.firez.one/capture/') - data = { - api_key: 'phc_ubuPhiqqjMdedpmbWpG2Ak3axqv5eMVhFDNBaXl9UZK', - event: 'firezone-ctl reconfigure', - properties: { - distinct_id: telemetry_id - } - } - return if File.exist?('/var/opt/firezone/.disable_telemetry') || ENV['TELEMETRY_ENABLED'] == 'false' - - Net::HTTP.post(uri, data.to_json, 'Content-Type' => 'application/json') -rescue StandardError => e - e -end -# rubocop:enable Metrics/MethodLength - -add_command_under_category 'reconfigure', 'general', 'Reconfigure the application.', 2 do - status = run_chef("#{base_path}/embedded/cookbooks/dna.json", '--chef-license=accept') - - capture - - if status.success? - log "#{display_name} Reconfigured!" - exit! 0 - else - exit! 1 - end -end diff --git a/omnibus/cookbooks/firezone/files/default/ctl-commands/reset_network.rb b/omnibus/cookbooks/firezone/files/default/ctl-commands/reset_network.rb deleted file mode 100644 index 3f7c3615d..000000000 --- a/omnibus/cookbooks/firezone/files/default/ctl-commands/reset_network.rb +++ /dev/null @@ -1,18 +0,0 @@ -# frozen_string_literal: true - -require 'mixlib/shellout' - -add_command_under_category 'reset-network', 'general', 'Sets WireGuard interface IP, enables packet forwarding, '\ - 'and routing table back to Firezone defaults.', 2 do - command = %W( - chef-client - -z - -l info - -c #{base_path}/embedded/cookbooks/solo.rb - -o recipe[firezone::teardown],recipe[firezone::network] - ) - - result = run_command(command.join(' ')) - remove_old_node_state - Kernel.exit 1 unless result.success? -end diff --git a/omnibus/cookbooks/firezone/files/default/ctl-commands/stop_renewal.rb b/omnibus/cookbooks/firezone/files/default/ctl-commands/stop_renewal.rb deleted file mode 100644 index 73e1eb634..000000000 --- a/omnibus/cookbooks/firezone/files/default/ctl-commands/stop_renewal.rb +++ /dev/null @@ -1,48 +0,0 @@ -# frozen_string_literal: true - -require 'mixlib/shellout' -require 'uri' -require 'net/http' -require 'json' - -# rubocop:disable Metrics/MethodLength -def capture - telemetry_file = '/var/opt/firezone/cache/telemetry_id' - return unless File.exist?(telemetry_file) - - telemetry_id = File.read(telemetry_file) - - return unless telemetry_id - - uri = URI('https://t.firez.one/capture/') - data = { - api_key: 'phc_ubuPhiqqjMdedpmbWpG2Ak3axqv5eMVhFDNBaXl9UZK', - event: 'firezone-ctl stop-cert-renewal', - properties: { - distinct_id: telemetry_id - } - } - return if File.exist?('/var/opt/firezone/.disable_telemetry') || ENV['TELEMETRY_ENABLED'] == 'false' - - Net::HTTP.post(uri, data.to_json, 'Content-Type' => 'application/json') -rescue StandardError => e - e -end -# rubocop:enable Metrics/MethodLength - -add_command_under_category 'stop-cert-renewal', 'general', 'Removes cronjob that renews certificates.', - 2 do - command = %W( - chef-client - -z - -l info - -c #{base_path}/embedded/cookbooks/solo.rb - -o recipe[firezone::stop_renewal] - ) - - capture - - result = run_command(command.join(' ')) - remove_old_node_state - Kernel.exit 1 unless result.success? -end diff --git a/omnibus/cookbooks/firezone/files/default/ctl-commands/teardown.rb b/omnibus/cookbooks/firezone/files/default/ctl-commands/teardown.rb deleted file mode 100644 index 7a2e9c3a4..000000000 --- a/omnibus/cookbooks/firezone/files/default/ctl-commands/teardown.rb +++ /dev/null @@ -1,18 +0,0 @@ -# frozen_string_literal: true - -require 'mixlib/shellout' - -add_command_under_category 'teardown-network', 'general', 'Removes WireGuard interface and firezone nftables table.', - 2 do - command = %W( - chef-client - -z - -l info - -c #{base_path}/embedded/cookbooks/solo.rb - -o recipe[firezone::teardown] - ) - - result = run_command(command.join(' ')) - remove_old_node_state - Kernel.exit 1 unless result.success? -end diff --git a/omnibus/cookbooks/firezone/files/default/ctl-commands/version.rb b/omnibus/cookbooks/firezone/files/default/ctl-commands/version.rb deleted file mode 100644 index 52013f511..000000000 --- a/omnibus/cookbooks/firezone/files/default/ctl-commands/version.rb +++ /dev/null @@ -1,27 +0,0 @@ -# frozen_string_literal: true - -# -# Copyright:: Copyright (c) 2019 Chef Software, Inc. -# Copyright:: Copyright (c) 2021 Firezone, Inc. -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -require 'json' - -add_command_under_category 'version', 'general', 'Display current version of Firezone', 2 do - version = JSON.parse(File.read('/opt/firezone/version-manifest.json'))['build_version'] - puts version -rescue Errno::ENOENT => e - puts 'Error determining version!' - puts e.message.to_s - exit(1) -end diff --git a/omnibus/cookbooks/firezone/kitchen.yml b/omnibus/cookbooks/firezone/kitchen.yml deleted file mode 100644 index e293f9546..000000000 --- a/omnibus/cookbooks/firezone/kitchen.yml +++ /dev/null @@ -1,32 +0,0 @@ ---- -driver: - name: vagrant - -## The forwarded_port port feature lets you connect to ports on the VM guest via -## localhost on the host. -## see also: https://www.vagrantup.com/docs/networking/forwarded_ports - -# network: -# - ["forwarded_port", {guest: 80, host: 8080}] - -provisioner: - name: chef_zero - - ## product_name and product_version specifies a specific Chef product and version to install. - ## see the Chef documentation for more details: https://docs.chef.io/workstation/config_yml_kitchen/ - # product_name: chef - # product_version: 17 - -verifier: - name: inspec - -platforms: - - name: ubuntu-20.04 - - name: centos-8 - -suites: - - name: default - verifier: - inspec_tests: - - test/integration/default - attributes: diff --git a/omnibus/cookbooks/firezone/libraries/config.rb b/omnibus/cookbooks/firezone/libraries/config.rb deleted file mode 100644 index 7792c38c1..000000000 --- a/omnibus/cookbooks/firezone/libraries/config.rb +++ /dev/null @@ -1,314 +0,0 @@ -# frozen_string_literal: false - -require 'json' -require 'fileutils' -require 'securerandom' - -# Manages configuration -class Firezone - # rubocop:disable Metrics/ModuleLength - # Config module - module Config - class IncompleteConfig < StandardError; end - class IncompatibleConfig < StandardError; end - - # rubocop:disable Metrics/MethodLength - def self.load_or_create!(filename, node) - create_directory!(filename) - if File.exist?(filename) - node.from_file(filename) - else - # Write out the new file, but with everything commented out - File.open(filename, 'w') do |file| - File.open( - "#{node['firezone']['install_directory']}/embedded/cookbooks/firezone/attributes/default.rb", 'r' - ).read.each_line do |line| - file.write "# #{line}" - end - end - Chef::Log.info("Creating configuration file #{filename}") - end - rescue Errno::ENOENT => e - Chef::Log.warn "Could not create #{filename}: #{e}" - end - # rubocop:enable Metrics/MethodLength - - def self.load_or_create_telemetry_id(filename, node) - create_directory!(filename) - if File.exist?(filename) - node.consume_attributes('firezone' => { 'telemetry_id' => File.read(filename) }) - else - telemetry_id = SecureRandom.uuid - File.open(filename, 'w') do |file| - file.write telemetry_id - end - node.consume_attributes('firezone' => { 'telemetry_id' => telemetry_id }) - end - end - - def self.locale_variables - <<~LOCALE - export LANG=en_US.UTF-8 - export LANGUAGE=en_US - export LC_CTYPE="en_US.UTF-8" - export LC_NUMERIC="en_US.UTF-8" - export LC_TIME="en_US.UTF-8" - export LC_COLLATE="en_US.UTF-8" - export LC_MONETARY="en_US.UTF-8" - export LC_MESSAGES="en_US.UTF-8" - export LC_PAPER="en_US.UTF-8" - export LC_NAME="en_US.UTF-8" - export LC_ADDRESS="en_US.UTF-8" - export LC_TELEPHONE="en_US.UTF-8" - export LC_MEASUREMENT="en_US.UTF-8" - export LC_IDENTIFICATION="en_US.UTF-8" - export LC_ALL="en_US.UTF-8" - LOCALE - end - - # Read in a JSON file for attributes and consume them - def self.load_from_json!(filename, node) - create_directory!(filename) - if File.exist?(filename) - node.consume_attributes( - 'firezone' => Chef::JSONCompat.from_json(File.open(filename).read) - ) - end - rescue StandardError => e - Chef::Log.warn "Could not read attributes from #{filename}: #{e}" - end - - # Read in the filename (as JSON) and add its attributes to the node object. - # If it doesn't exist, create it with generated secrets. - def self.load_or_create_secrets!(filename, node) - create_directory!(filename) - secrets = build_secrets(node) - - # Merge in existing secrets from JSON file - File.exist?(filename) && secrets.merge!(Chef::JSONCompat.from_json(File.read(filename))) - - # Apply to running system - node.consume_attributes('firezone' => secrets) - - # Save them for next run - write_secrets(filename, secrets) - end - - def self.write_secrets(filename, secrets) - File.open(filename, 'w') do |file| - file.puts Chef::JSONCompat.to_json_pretty(secrets) - end - Chef::Log.info("Creating secrets file #{filename}") - rescue Errno::EACCES, Errno::ENOENT => e - Chef::Log.warn "Could not create #{filename}: #{e}" - end - - # rubocop:disable Metrics/PerceivedComplexity - # rubocop:disable Metrics/MethodLength - # rubocop:disable Metrics/CyclomaticComplexity - # rubocop:disable Metrics/AbcSize - def self.build_secrets(node) - { - 'guardian_secret_key' => node['firezone'] && node['firezone']['guardian_secret_key'] || SecureRandom.base64(48), - 'secret_key_base' => node['firezone'] && node['firezone']['secret_key_base'] || SecureRandom.base64(48), - 'live_view_signing_salt' => node['firezone'] && node['firezone']['live_view_signing_salt'] || \ - SecureRandom.base64(24), - 'cookie_signing_salt' => node['firezone'] && node['firezone']['cookie_signing_salt'] || SecureRandom.base64(6), - 'cookie_encryption_salt' => node['firezone'] && node['firezone']['cookie_encryption_salt'] || \ - SecureRandom.base64(6), - 'database_encryption_key' => node['firezone'] && node['firezone']['database_encryption_key'] || \ - SecureRandom.base64(32), - 'default_admin_password' => node['firezone'] && node['firezone']['default_admin_password'] || \ - SecureRandom.base64(12) - } - end - # rubocop:enable Metrics/PerceivedComplexity - # rubocop:enable Metrics/MethodLength - # rubocop:enable Metrics/CyclomaticComplexity - # rubocop:enable Metrics/AbcSize - - def self.audit_config(config) - audit_fips_config(config) - end - - def self.audit_fips_config(config) - return if built_with_fips?(config['install_directory']) - - if fips_enabled_in_kernel? - raise IncompatibleConfig, - 'Detected FIPS is enabled in the kernel, but FIPS is not supported by this installer.' - end - return unless config['fips_enabled'] - - raise IncompatibleConfig, - 'You have enabled FIPS in your configuration, but FIPS is not supported by this installer.' - end - - def self.built_with_fips?(install_directory) - File.exist?("#{install_directory}/embedded/lib/fipscanister.o") - end - - def self.fips_enabled_in_kernel? - fips_path = '/proc/sys/crypto/fips_enabled' - (File.exist?(fips_path) && File.read(fips_path).chomp != '0') - end - - # rubocop:disable Metrics/MethodLength - # rubocop:disable Metrics/AbcSize - def self.maybe_turn_on_fips(node) - # the compexity of this method is currently needed to figure out what words to display - # to the poor human who has to deal with FIPS - case node['firezone']['fips_enabled'] - when nil - # the default value, set fips mode based on whether it is enabled in the kernel - node.normal['firezone']['fips_enabled'] = Firezone::Config.fips_enabled_in_kernel? - if node['firezone']['fips_enabled'] - Chef::Log.warn('Detected FIPS-enabled kernel; enabling FIPS 140-2 for Firezone services.') - end - when false - node.normal['firezone']['fips_enabled'] = Firezone::Config.fips_enabled_in_kernel? - if node['firezone']['fips_enabled'] - Chef::Log.warn('Detected FIPS-enabled kernel; enabling FIPS 140-2 for Firezone services.') - Chef::Log.warn('fips_enabled was set to false; ignoring this and setting to true or else Firezone services'\ - ' will fail with crypto errors.') - end - when true - Chef::Log.warn('Overriding FIPS detection: FIPS 140-2 mode is ON.') - else - node.normal['firezone']['fips_enabled'] = true - Chef::Log.warn( - 'fips_enabled is set to something other than boolean true/false; assuming FIPS mode should be enabled.' - ) - Chef::Log.warn('Overriding FIPS detection: FIPS 140-2 mode is ON.') - end - end - # rubocop:enable Metrics/MethodLength - # rubocop:enable Metrics/AbcSize - - # Take some node attributes and return them on each line as: - # - # export ATTR_NAME="attr_value" - # - # If the value is a String or Number and the attribute name is attr_name. - # Used to write out environment variables to a file. - def self.environment_variables_from(attributes) - attributes.reduce '' do |str, attr| - str << if attr[1].is_a?(String) || attr[1].is_a?(Numeric) || attr[1] == true || attr[1] == false - "export #{attr[0].upcase}=\"#{attr[1]}\"\n" - else - '' - end - end - end - - # rubocop:disable Metrics/MethodLength - # rubocop:disable Metrics/AbcSize - # rubocop:disable Metrics/CyclomaticComplexity - def self.app_env(node, reject = []) - attributes = node['firezone'] - attributes = attributes.reject { |k| reject.include?(k) } - - fqdn_url = "https://#{attributes['fqdn'] || node['fqdn'] || node['hostname']}" - - # NOTE: All these variables must be Strings - env = { - 'GATEWAY_EGRESS_INTERFACE' => attributes['egress_interface'], - 'GATEWAY_NFT_PATH' => "#{attributes['install_directory']}/embedded/sbin/nft", - 'MIX_ENV' => 'prod', - 'DATABASE_NAME' => attributes['database']['name'], - 'DATABASE_USER' => attributes['database']['user'], - 'DATABASE_HOST' => attributes['database']['host'], - 'DATABASE_PORT' => attributes['database']['port'].to_s, - 'DATABASE_POOL' => attributes['database']['pool'].to_s, - 'DATABASE_SSL' => attributes['database']['ssl'].to_s, - 'DATABASE_SSL_OPTS' => attributes['database']['ssl_opts'].to_json, - 'DATABASE_PARAMETERS' => attributes['database']['parameters'].to_json, - 'PHOENIX_LISTEN_ADDRESS' => attributes['phoenix']['listen_address'].to_s, - 'PHOENIX_HTTP_PORT' => attributes['phoenix']['port'].to_s, - 'PHOENIX_EXTERNAL_TRUSTED_PROXIES' => - Chef::JSONCompat.to_json(attributes['phoenix']['external_trusted_proxies']), - 'PHOENIX_PRIVATE_CLIENTS' => Chef::JSONCompat.to_json(attributes['phoenix']['private_clients']), - 'EXTERNAL_URL' => attributes['external_url'] || fqdn_url, - 'DEFAULT_ADMIN_EMAIL' => attributes['admin_email'], - 'WIREGUARD_INTERFACE_NAME' => attributes['wireguard']['interface_name'], - 'WIREGUARD_PORT' => attributes['wireguard']['port'].to_s, - 'WIREGUARD_MTU' => attributes['wireguard']['mtu'].to_s, - 'DEFAULT_CLIENT_ENDPOINT' => attributes['wireguard']['endpoint'].to_s, - 'DEFAULT_CLIENT_DNS' => attributes['wireguard']['dns'].to_s, - 'WIREGUARD_ALLOWED_IPS' => attributes['wireguard']['allowed_ips'].to_s, - 'WIREGUARD_PERSISTENT_KEEPALIVE' => attributes['wireguard']['persistent_keepalive'].to_s, - 'WIREGUARD_IPV4_ENABLED' => attributes['wireguard']['ipv4']['enabled'].to_s, - 'WIREGUARD_IPV4_MASQUERADE' => attributes['wireguard']['ipv4']['masquerade'].to_s, - 'WIREGUARD_IPV4_NETWORK' => attributes['wireguard']['ipv4']['network'], - 'WIREGUARD_IPV4_ADDRESS' => attributes['wireguard']['ipv4']['address'], - 'WIREGUARD_IPV6_MASQUERADE' => attributes['wireguard']['ipv6']['masquerade'].to_s, - 'WIREGUARD_IPV6_ENABLED' => attributes['wireguard']['ipv6']['enabled'].to_s, - 'WIREGUARD_IPV6_NETWORK' => attributes['wireguard']['ipv6']['network'], - 'WIREGUARD_IPV6_ADDRESS' => attributes['wireguard']['ipv6']['address'], - 'MAX_DEVICES_PER_USER' => attributes['max_devices_per_user'].to_s, - 'ALLOW_UNPRIVILEGED_DEVICE_MANAGEMENT' => attributes['allow_unprivileged_device_management'].to_s, - 'ALLOW_UNPRIVILEGED_DEVICE_CONFIGURATION' => attributes['allow_unprivileged_device_configuration'].to_s, - - # Allow env var to override config - 'TELEMETRY_ENABLED' => ENV.fetch('TELEMETRY_ENABLED', - attributes['telemetry']['enabled'] == false ? 'false' : 'true'), - 'TELEMETRY_ID' => attributes['telemetry_id'], - 'CONNECTIVITY_CHECKS_ENABLED' => attributes['connectivity_checks']['enabled'].to_s, - 'CONNECTIVITY_CHECKS_INTERVAL' => attributes['connectivity_checks']['interval'].to_s, - - # Outbound Emails - 'OUTBOUND_EMAIL_ADAPTER' => attributes['outbound_email']['provider'], - 'OUTBOUND_EMAIL_ADAPTER_OPTS' => attributes['outbound_email']['configs'].to_json, - 'OUTBOUND_EMAIL_FROM' => attributes['outbound_email']['from'], - - # XXX: Remove this in the future when we're fairly sure that users won't upgrade across - # the <= 0.4.4 to >= 0.4.5 version boundary. - 'WIREGUARD_PRIVATE_KEY_PATH' => "#{node['firezone']['var_directory']}/cache/wg_private_key", - - 'SAML_KEYFILE_PATH' => "#{node['firezone']['ssl']['directory']}/saml.key", - 'SAML_CERTFILE_PATH' => "#{node['firezone']['ssl']['directory']}/saml.crt", - - # Auth - 'LOCAL_AUTH_ENABLED' => attributes['authentication']['local']['enabled'].to_s, - - 'DISABLE_VPN_ON_OIDC_ERROR' => attributes['authentication']['disable_vpn_on_oidc_error'].to_s, - - # OpenID Connect auth settings are serialized to json for consumption by fz_http - 'OPENID_CONNECT_PROVIDERS' => attributes['authentication']['oidc'].to_json, - # SAML auth settings are serialized to json for consumption by fz_http - 'SAML_IDENTITY_PROVIDERS' => attributes['authentication']['saml'].to_json, - - # secrets - 'GUARDIAN_SECRET_KEY' => attributes['guardian_secret_key'], - 'SECRET_KEY_BASE' => attributes['secret_key_base'], - 'LIVE_VIEW_SIGNING_SALT' => attributes['live_view_signing_salt'], - 'COOKIE_SIGNING_SALT' => attributes['cookie_signing_salt'], - 'COOKIE_ENCRYPTION_SALT' => attributes['cookie_encryption_salt'], - 'DATABASE_ENCRYPTION_KEY' => attributes['database_encryption_key'], - - # cookies - 'SECURE_COOKIES' => attributes['phoenix']['secure_cookies'].to_s - } - - env.merge!('DATABASE_PASSWORD' => attributes['database']['password']) if attributes.dig('database', 'password') - - if attributes['default_admin_password'] - env.merge!('DEFAULT_ADMIN_PASSWORD' => attributes['default_admin_password']) - end - - env - end - # rubocop:enable Metrics/CyclomaticComplexity - # rubocop:enable Metrics/MethodLength - # rubocop:enable Metrics/AbcSize - - def self.create_directory!(filename) - dir = File.dirname(filename) - FileUtils.mkdir(dir, mode: 0o700) unless Dir.exist?(dir) - rescue Errno::EACCES => e - Chef::Log.warn "Could not create #{dir}: #{e}" - end - private_class_method :create_directory! - end - # rubocop:enable Metrics/ModuleLength -end diff --git a/omnibus/cookbooks/firezone/metadata.rb b/omnibus/cookbooks/firezone/metadata.rb deleted file mode 100644 index ecfdfc7f2..000000000 --- a/omnibus/cookbooks/firezone/metadata.rb +++ /dev/null @@ -1,25 +0,0 @@ -# frozen_string_literal: true - -name 'firezone' -maintainer 'Firezone' -maintainer_email 'infra@firezone.dev' -license 'Apache-2.0' -description 'Installs/Configures firezone' -version '0.0.1' -chef_version '>= 16.0' - -depends 'enterprise' -depends 'runit' -depends 'line' - -# The `issues_url` points to the location where issues for this cookbook are -# tracked. A `View Issues` link will be displayed on this cookbook's page when -# uploaded to a Supermarket. -# -# issues_url 'https://github.com//firezone/issues' - -# The `source_url` points to the development repository for this cookbook. A -# `View Source` link will be displayed on this cookbook's page when uploaded to -# a Supermarket. -# -# source_url 'https://github.com//firezone' diff --git a/omnibus/cookbooks/firezone/recipes/acme.rb b/omnibus/cookbooks/firezone/recipes/acme.rb deleted file mode 100644 index 24b33fa75..000000000 --- a/omnibus/cookbooks/firezone/recipes/acme.rb +++ /dev/null @@ -1,103 +0,0 @@ -# frozen_string_literal: true - -# Cookbook:: firezone -# Recipe:: acme -# -# Copyright:: 2022, Firezone, All Rights Reserved. - -include_recipe 'firezone::config' - -bin_path = "#{node['firezone']['install_directory']}/embedded/bin" - -file "#{bin_path}/acme.sh" do - mode '0770' - owner 'root' - group 'root' -end - -# Remove cronjob to make sure it's correctly re-created -# and remove even if acme is disabled. -execute 'ACME remove cronjob' do - command <<~ACME - #{bin_path}/acme.sh --uninstall-cronjob - ACME -end - -# Enable ACME if set to enabled and user-specified certs are disabled, maintains -# backwards compatibility during upgrades. -if node['firezone']['ssl']['acme']['enabled'] && !node['firezone']['ssl']['certificate'] - - keylength = node['firezone']['ssl']['acme']['keylength'] - server = node['firezone']['ssl']['acme']['server'] - # We include the server in acme's home to force it to re-generate - acme_home = "#{node['firezone']['var_directory']}/#{server}/#{keylength}/acme" - fqdn = URI.parse(node['firezone']['external_url']).host - certfile = "#{node['firezone']['var_directory']}/ssl/acme/#{fqdn}.cert" - keyfile = "#{node['firezone']['var_directory']}/ssl/acme/#{fqdn}.key" - fullchainfile = "#{node['firezone']['var_directory']}/ssl/acme/#{fqdn}.fullchain" - is_ecc = keylength.include? 'ec' - - directory acme_home do - mode '0770' - owner 'root' - group 'root' - recursive true - end - - execute 'ACME initialization' do - # Need to cwd to bin_path because ACME expects to copy itself - cwd bin_path - command <<~ACME - ./acme.sh --install \ - --debug \ - --home #{acme_home} \ - --accountemail "#{node['firezone']['ssl']['email_address']}" - ACME - end - - execute 'ACME registration' do - command <<~ACME - #{bin_path}/acme.sh --register-account \ - --home #{acme_home} \ - --server #{server} \ - --debug \ - -m #{node['firezone']['ssl']['email_address']} - ACME - end - - # Pick up any nginx conf changes that may have happened during this Chef run - execute 'Reload Nginx' do - notifies :reload, 'component_runit_service[nginx]', :immediately - command 'echo "reloading nginx..."' - end - - execute 'ACME issue' do - # Command returns 0: Cert was issued - # Command returns 2: Skipping because renewal isn't needed - returns [0, 2] - command <<~ACME - #{bin_path}/acme.sh --issue \ - --home #{acme_home} \ - --server #{server} \ - --keylength #{keylength} \ - --debug \ - -d #{URI.parse(node['firezone']['external_url']).host} \ - -w #{node['firezone']['var_directory']}/nginx/acme_root - ACME - end - - execute 'ACME install-cert' do - command <<~ACME - #{bin_path}/acme.sh --install-cert \ - --home #{acme_home} \ - --debug \ - -d #{fqdn} \ - #{'--ecc' if is_ecc} \ - --cert-file "#{certfile}" \ - --key-file "#{keyfile}" \ - --server #{server} \ - --fullchain-file "#{fullchainfile}" \ - --reloadcmd "firezone-ctl hup nginx" - ACME - end -end diff --git a/omnibus/cookbooks/firezone/recipes/app.rb b/omnibus/cookbooks/firezone/recipes/app.rb deleted file mode 100644 index 3aee83136..000000000 --- a/omnibus/cookbooks/firezone/recipes/app.rb +++ /dev/null @@ -1,64 +0,0 @@ -# frozen_string_literal: true - -# Cookbook:: firezone -# Recipe:: app -# -# Copyright:: 2014 Chef Software, Inc. -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -# - -include_recipe 'firezone::config' -include_recipe 'firezone::phoenix' - -execute 'fix app permissions' do - app_dir = node['firezone']['app_directory'] - user = node['firezone']['user'] - group = node['firezone']['group'] - command "chown -R #{user}:#{group} #{app_dir} && chmod -R o-rwx #{app_dir} && chmod -R g-rwx #{app_dir}" -end - -beam_path = `ls -1 #{node['firezone']['install_directory']}/embedded/service/firezone/erts-*/bin/beam.smp \ - | sort -nr | head -n 1 | tr -d '\n'` -execute 'setcap_beam' do - command "setcap 'cap_net_admin+eip' #{beam_path}" - node['firezone']['phoenix']['enabled'] && notifies(:restart, 'component_runit_service[phoenix]', :delayed) -end - -file 'environment-variables' do - path "#{node['firezone']['var_directory']}/etc/env" - - attributes = node['firezone'].to_hash - - # Remove sensitive fields that aren't required for application startup - attributes.delete('wireguard_private_key') - attributes.delete('default_admin_password') - - # Add needed fields to top-level so they get added to application env and get - # updated when config is updated. - attributes.merge!( - 'mix_env' => 'prod' - ) - - content Firezone::Config.environment_variables_from(attributes) - owner node['firezone']['user'] - group node['firezone']['group'] - mode '0600' -end - -execute 'database schema' do - command 'bin/firezone eval "FzHttp.Release.migrate"' - cwd node['firezone']['app_directory'] - environment(Firezone::Config.app_env(node)) - user node['firezone']['user'] -end diff --git a/omnibus/cookbooks/firezone/recipes/config.rb b/omnibus/cookbooks/firezone/recipes/config.rb deleted file mode 100644 index d22976a79..000000000 --- a/omnibus/cookbooks/firezone/recipes/config.rb +++ /dev/null @@ -1,108 +0,0 @@ -# frozen_string_literal: true - -require 'securerandom' - -# Cookbook:: firezone -# Recipe:: config -# -# Copyright:: 2014 Chef Software, Inc. -# Copyright:: 2021 Firezone, Inc. -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -# - -# Get and/or create config and secrets. -# -# This creates the config_directory if it does not exist as well as the files -# in it. - -Firezone::Config.load_or_create!( - "#{node['firezone']['config_directory']}/firezone.rb", - node -) -Firezone::Config.load_or_create_telemetry_id("#{node['firezone']['var_directory']}/cache/telemetry_id", node) -Firezone::Config.load_from_json!( - "#{node['firezone']['config_directory']}/firezone.json", - node -) -Firezone::Config.load_or_create_secrets!( - "#{node['firezone']['config_directory']}/secrets.json", - node -) - -Firezone::Config.audit_config(node['firezone']) -Firezone::Config.maybe_turn_on_fips(node) - -# Set SSL email address to admin's email if none was provided. -node.default['firezone']['ssl']['email_address'] ||= node['firezone']['admin_email'] - -# Copy things we need from the firezone namespace to the top level. This is -# necessary for some community cookbooks. -node.consume_attributes('runit' => node['firezone']['runit']) - -user node['firezone']['user'] - -group node['firezone']['group'] do - members [node['firezone']['user']] -end - -directory node['firezone']['config_directory'] do - owner node['firezone']['user'] - group node['firezone']['group'] -end - -directory node['firezone']['var_directory'] do - owner node['firezone']['user'] - group node['firezone']['group'] - mode '0700' - recursive true -end - -directory "#{node['firezone']['app_directory']}/tmp" do - owner node['firezone']['user'] - group node['firezone']['group'] - mode '0700' - recursive true -end - -directory node['firezone']['log_directory'] do - owner node['firezone']['user'] - group node['firezone']['group'] - mode '0700' - recursive true -end - -directory "#{node['firezone']['var_directory']}/etc" do - owner node['firezone']['user'] - group node['firezone']['group'] - mode '0700' -end - -file 'configuration-variables' do - path "#{node['firezone']['config_directory']}/firezone.rb" - owner node['firezone']['user'] - group node['firezone']['group'] - mode '0600' -end - -file "#{node['firezone']['config_directory']}/secrets.json" do - owner node['firezone']['user'] - group node['firezone']['group'] - mode '0600' -end - -file "#{node['firezone']['var_directory']}/cache/wg_private_key" do - owner node['firezone']['user'] - group node['firezone']['group'] - mode '0600' -end diff --git a/omnibus/cookbooks/firezone/recipes/create_admin.rb b/omnibus/cookbooks/firezone/recipes/create_admin.rb deleted file mode 100644 index f07100476..000000000 --- a/omnibus/cookbooks/firezone/recipes/create_admin.rb +++ /dev/null @@ -1,49 +0,0 @@ -# frozen_string_literal: true - -# Cookbook:: firezone -# Recipe:: create_admin -# -# Copyright:: 2014 Chef Software, Inc. -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -# - -include_recipe 'firezone::config' - -execute 'create_admin' do - command 'bin/firezone eval "FzHttp.Release.create_admin_user"' - cwd node['firezone']['app_directory'] - environment(Firezone::Config.app_env(node)) - user node['firezone']['user'] -end - -log 'admin_created' do - external_url = - node['firezone']['external_url'] || "https://#{node['firezone']['fqdn'] || node['fqdn'] || node['hostname']}" - - msg = <<~MSG - ================================================================================= - - Firezone user created! Save this information because it will NOT be shown again. - - Use these credentials to sign in to the web UI at #{external_url}. - - Email: #{node['firezone']['admin_email']} - Password: #{node['firezone']['default_admin_password']} - - ================================================================================= - MSG - - message msg - level :info # info and below are not shown by default -end diff --git a/omnibus/cookbooks/firezone/recipes/database.rb b/omnibus/cookbooks/firezone/recipes/database.rb deleted file mode 100644 index d3c9eea00..000000000 --- a/omnibus/cookbooks/firezone/recipes/database.rb +++ /dev/null @@ -1,58 +0,0 @@ -# frozen_string_literal: true - -# Cookbook:: firezone -# Recipe:: database -# -# Copyright:: 2014 Chef Software, Inc. -# Copyright:: 2021 Firezone, Inc. -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -# - -include_recipe 'firezone::config' - -# The enterprise_pg resources use the CLI to create databases and users. Set -# these environment variables so the commands have the correct connection -# settings. - -ENV['PGHOST'] = node['firezone']['database']['host'] -ENV['PGPORT'] = node['firezone']['database']['port'].to_s -ENV['PGUSER'] = node['firezone']['database']['user'] -ENV['PGPASSWORD'] = node['firezone']['database']['password'] -ENV['PGDATABASE'] = node['firezone']['database']['name'] - -unless node['firezone']['database']['create_user'] == false - enterprise_pg_user node['firezone']['database']['user'] do - superuser true - password node['firezone']['database']['password'] || '' - # If the database user is the same as the main postgres user, don't create it. - not_if do - node['firezone']['database']['user'] == - node['firezone']['postgresql']['username'] - end - end -end - -unless node['firezone']['database']['create_db'] == false - enterprise_pg_database node['firezone']['database']['name'] do - owner node['firezone']['database']['user'] - end -end - -node['firezone']['database']['extensions'].each do |ext, _enable| - execute "create postgresql #{ext} extension" do - user node['firezone']['database']['user'] - command "echo 'CREATE EXTENSION IF NOT EXISTS #{ext}' | psql" - not_if "echo '\\dx' | psql #{node['firezone']['database']['name']} | grep #{ext}" - end -end diff --git a/omnibus/cookbooks/firezone/recipes/default.rb b/omnibus/cookbooks/firezone/recipes/default.rb deleted file mode 100644 index 63cfc5399..000000000 --- a/omnibus/cookbooks/firezone/recipes/default.rb +++ /dev/null @@ -1,46 +0,0 @@ -# frozen_string_literal: true - -# Cookbook:: firezone -# Recipe:: default -# -# Copyright:: 2021, Firezone, All Rights Reserved. - -include_recipe 'firezone::config' -include_recipe 'firezone::log_management' -include_recipe 'firezone::ssl' -include_recipe 'firezone::network' -include_recipe 'firezone::postgresql' -include_recipe 'firezone::nginx' -include_recipe 'firezone::acme' -include_recipe 'firezone::database' -include_recipe 'firezone::setcap' -include_recipe 'firezone::app' -include_recipe 'firezone::telemetry' - -running_config = "#{node['firezone']['config_directory']}/firezone-running.json" -if File.exist?(running_config) - old_interface = Chef::JSONCompat.from_json(File.open(running_config).read)['firezone']['wireguard']['interface_name'] -end - -# Write out a firezone-running.json at the end of the run -file running_config do - content Chef::JSONCompat.to_json_pretty('firezone' => node['firezone']) - owner node['firezone']['user'] - group node['firezone']['group'] - mode '0600' -end - -file "#{node['firezone']['var_directory']}/.license.accepted" do - content '' - owner node['firezone']['user'] - group node['firezone']['group'] - mode '0600' -end - -if File.exist?(running_config) - # Run at the end to try to minimize VPN disruption. - execute 'handle_interface_change' do - only_if (old_interface != node['firezone']['wireguard']['interface_name']).to_s - command "ip link del dev #{old_interface}" - end -end diff --git a/omnibus/cookbooks/firezone/recipes/force_renewal.rb b/omnibus/cookbooks/firezone/recipes/force_renewal.rb deleted file mode 100644 index 3c106a2e6..000000000 --- a/omnibus/cookbooks/firezone/recipes/force_renewal.rb +++ /dev/null @@ -1,25 +0,0 @@ -# frozen_string_literal: true - -# Cookbook:: firezone -# Recipe:: force_renewal -# -# Copyright:: 2021, Firezone, All Rights Reserved. - -# Force certificate to renew now even if it hasn't expired. - -include_recipe 'firezone::config' - -require 'mixlib/shellout' - -server = node['firezone']['ssl']['acme']['server'] -keylength = node['firezone']['ssl']['acme']['keylength'] -bin_path = "#{node['firezone']['install_directory']}/embedded/bin" -acme_home = "#{node['firezone']['var_directory']}/#{server}/#{keylength}/acme" - -execute 'ACME force cronjob' do - command <<~ACME - #{bin_path}/acme.sh --cron \ - --force \ - --home #{acme_home} - ACME -end diff --git a/omnibus/cookbooks/firezone/recipes/log_management.rb b/omnibus/cookbooks/firezone/recipes/log_management.rb deleted file mode 100644 index e89a47f9d..000000000 --- a/omnibus/cookbooks/firezone/recipes/log_management.rb +++ /dev/null @@ -1,54 +0,0 @@ -# frozen_string_literal: true - -# -# Cookbook:: firezone -# Recipe:: log_management -# -# Copyright:: 2015 Chef Software, Inc. -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -# - -# Firezone log management is mostly handled by runit, svlogd -# and each component service logged to STDOUT for svlogd to handle. Some -# components do not handle logging to STDOUT well, so logrotate is added -# to manage the logs generated by those services. - -include_recipe 'firezone::config' - -directory "#{node['firezone']['var_directory']}/etc/logrotate.d" do - owner 'root' - group 'root' - mode '0755' -end - -template "#{node['firezone']['var_directory']}/etc/logrotate.conf" do - source 'logrotate.conf.erb' - mode '0644' - owner 'root' - group 'root' - variables( - var_directory: node['firezone']['var_directory'] - ) -end - -template '/etc/cron.hourly/firezone_logrotate' do - source 'logrotate.cron.erb' - mode '0755' - owner 'root' - group 'root' - variables( - install_directory: node['firezone']['install_directory'], - var_directory: node['firezone']['var_directory'] - ) -end diff --git a/omnibus/cookbooks/firezone/recipes/network.rb b/omnibus/cookbooks/firezone/recipes/network.rb deleted file mode 100644 index 0d0817d48..000000000 --- a/omnibus/cookbooks/firezone/recipes/network.rb +++ /dev/null @@ -1,56 +0,0 @@ -# frozen_string_literal: true - -# Cookbook:: firezone -# Recipe:: network -# -# Copyright:: 2021, Firezone, All Rights Reserved. - -# Set up wireguard interface, default routes, and firewall -# rules so that Firezone can run without a hitch. -# -# This recipe basically performs the work of wg-quick without having to -# have a configuration file. - -include_recipe 'firezone::config' -include_recipe 'line::default' - -require 'mixlib/shellout' -require 'net/http' - -unless node['firezone']['wireguard']['endpoint'] - # Figure out a sane default endpoint IP address - egress_ip = - begin - # Parse to ensure we get back something usable. - URI.parse(Net::HTTP.get('ifconfig.me', '/')) - rescue StandardError => e - Chef::Log.warn(e) - nil - end - node.consume_attributes('firezone' => { 'wireguard' => { 'endpoint' => egress_ip } }) -end - -unless node['firezone']['egress_interface'] - # Use ip route for finding default egress interface - egress_int_cmd = Mixlib::ShellOut.new("ip route show default 0.0.0.0/0 | grep -oP '(?<=dev ).*' | cut -f1 -d' '") - egress_interface = egress_int_cmd.run_command.stdout.chomp - node.consume_attributes('firezone' => { 'egress_interface' => egress_interface }) -end - -replace_or_add 'IPv4 packet forwarding' do - path '/etc/sysctl.conf' - pattern(/^\s+#\s+net.ipv4.ip_forward\s+=\s+1/) - line 'net.ipv4.ip_forward=1' -end - -path = '/sys/module/ipv6/parameters/disable' -ipv6_enabled = File.exist?(path) && File.read(path).chomp == '0' -if ipv6_enabled - replace_or_add 'IPv6 packet forwarding' do - path '/etc/sysctl.conf' - pattern(/^\s+#\s+net.ipv6.conf.all.forwarding\s+=\s+1/) - line 'net.ipv6.conf.all.forwarding=1' - end -end - -execute 'sysctl -p /etc/sysctl.conf' diff --git a/omnibus/cookbooks/firezone/recipes/nginx.rb b/omnibus/cookbooks/firezone/recipes/nginx.rb deleted file mode 100644 index 07d51ce8c..000000000 --- a/omnibus/cookbooks/firezone/recipes/nginx.rb +++ /dev/null @@ -1,102 +0,0 @@ -# frozen_string_literal: true - -# -# Cookbook:: firezone -# Recipe:: nginx -# -# Copyright:: 2014 Chef Software, Inc. -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -# - -include_recipe 'firezone::config' - -[node['firezone']['nginx']['cache']['directory'], - node['firezone']['nginx']['log_directory'], - node['firezone']['nginx']['directory'], - "#{node['firezone']['nginx']['directory']}/conf.d", - "#{node['firezone']['nginx']['directory']}/sites-enabled", - "#{node['firezone']['var_directory']}/nginx/acme_root", - "#{node['firezone']['var_directory']}/nginx/acme_root/.well-known", - "#{node['firezone']['var_directory']}/nginx/acme_root/.well-known/acme-challenge"].each do |dir| - directory dir do - owner node['firezone']['user'] - group node['firezone']['group'] - mode '0700' - recursive true - end -end - -# Link the mime.types -link "#{node['firezone']['nginx']['directory']}/mime.types" do - to "#{node['firezone']['install_directory']}/embedded/conf/mime.types" -end - -template 'nginx.conf' do - path "#{node['firezone']['nginx']['directory']}/nginx.conf" - source 'nginx.conf.erb' - owner node['firezone']['user'] - group node['firezone']['group'] - mode '0600' - variables( - logging_enabled: node['firezone']['logging']['enabled'], - nginx: node['firezone']['nginx'] - ) -end - -template 'redirect.conf' do - path "#{node['firezone']['nginx']['directory']}/redirect.conf" - source 'redirect.conf.erb' - owner 'root' - group node['firezone']['group'] - mode '0640' - variables( - server_name: URI.parse(node['firezone']['external_url']).host, - acme_www_root: "#{node['firezone']['var_directory']}/nginx/acme_root", - rate_limiting_zone_name: node['firezone']['nginx']['rate_limiting_zone_name'], - ipv6: node['firezone']['nginx']['ipv6'], - acme: node['firezone']['ssl']['acme'] - ) -end - -if node['firezone']['nginx']['enabled'] - component_runit_service 'nginx' do - package 'firezone' - action :enable - subscribes :restart, 'template[nginx.conf]' - subscribes :restart, 'template[phoenix.nginx.conf]' - subscribes :restart, 'template[redirect.conf]' - subscribes :restart, 'template[acme.conf]' - end -else - runit_service 'nginx' do - action :disable - end -end - -# setup log rotation with logrotate because nginx and runit's svlogd -# differ in opinion about who does the logging -template "#{node['firezone']['var_directory']}/etc/logrotate.d/nginx" do - source 'logrotate-rule.erb' - owner 'root' - group 'root' - mode '0644' - variables( - 'log_directory' => node['firezone']['nginx']['log_directory'], - 'log_rotation' => node['firezone']['nginx']['log_rotation'], - 'postrotate' => "#{node['firezone']['install_directory']}/embedded/sbin/nginx -c "\ - "#{node['firezone']['nginx']['directory']}/nginx.conf -s reopen", - 'owner' => 'root', - 'group' => 'root' - ) -end diff --git a/omnibus/cookbooks/firezone/recipes/phoenix.rb b/omnibus/cookbooks/firezone/recipes/phoenix.rb deleted file mode 100644 index e89ebcebe..000000000 --- a/omnibus/cookbooks/firezone/recipes/phoenix.rb +++ /dev/null @@ -1,95 +0,0 @@ -# frozen_string_literal: true - -# Cookbook:: firezone -# Recipe:: phoenix -# -# Copyright:: 2014 Chef Software, Inc. -# Copyright:: 2021 Firezone -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -# - -# Common configuration for Phoenix - -include_recipe 'firezone::config' -include_recipe 'firezone::nginx' -include_recipe 'firezone::acme' -include_recipe 'firezone::ssl' -include_recipe 'firezone::wireguard' - -fqdn = URI.parse(node['firezone']['external_url']).host -acme_cert = "#{node['firezone']['var_directory']}/ssl/acme/#{fqdn}.fullchain" -acme_key = "#{node['firezone']['var_directory']}/ssl/acme/#{fqdn}.key" - -[node['firezone']['phoenix']['log_directory'], - "#{node['firezone']['var_directory']}/phoenix/run"].each do |dir| - directory dir do - owner node['firezone']['user'] - group node['firezone']['group'] - mode '0700' - recursive true - end -end - -if node['firezone']['ssl']['acme']['enabled'] - # Generate a temporary cert until ACME issues one so that nginx can be restarted - openssl_x509_certificate acme_cert do - common_name fqdn - org node['firezone']['ssl']['company_name'] - org_unit node['firezone']['ssl']['organizational_unit_name'] - country node['firezone']['ssl']['country_name'] - key_length 2048 - expire 3650 - owner 'root' - group 'root' - mode '0644' - end -end - -template 'phoenix.nginx.conf' do - path "#{node['firezone']['nginx']['directory']}/sites-enabled/phoenix" - source 'phoenix.nginx.conf.erb' - owner node['firezone']['user'] - group node['firezone']['group'] - mode '0600' - variables(nginx: node['firezone']['nginx'], - logging_enabled: node['firezone']['logging']['enabled'], - phoenix: node['firezone']['phoenix'], - fqdn: fqdn, - fips_enabled: node['firezone']['fips_enabled'], - ssl: node['firezone']['ssl'], - app_directory: node['firezone']['app_directory'], - acme: { - 'enabled' => node['firezone']['ssl']['acme']['enabled'], - 'certificate' => acme_cert, - 'certificate_key' => acme_key - }) -end - -if node['firezone']['phoenix']['enabled'] - component_runit_service 'phoenix' do - runit_attributes( - env: Firezone::Config.app_env(node), - finish: true - ) - package 'firezone' - control ['t'] - action :enable - subscribes :restart, 'file[environment-variables]' - subscribes :restart, 'file[disable-telemetry]' - end -else - runit_service 'phoenix' do - action :disable - end -end diff --git a/omnibus/cookbooks/firezone/recipes/postgresql.rb b/omnibus/cookbooks/firezone/recipes/postgresql.rb deleted file mode 100644 index 4f2f4bc68..000000000 --- a/omnibus/cookbooks/firezone/recipes/postgresql.rb +++ /dev/null @@ -1,56 +0,0 @@ -# frozen_string_literal: true - -# -# Cookbook:: firezone -# Recipe:: postgresql -# -# Copyright:: 2014 Chef Software, Inc. -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -# - -include_recipe 'firezone::config' -include_recipe 'enterprise::runit' - -# These sysctl settings make the shared memory settings work for larger -# instances -%w[shmmax shmall].each do |param| - sysctl "kernel.#{param}" do - value node['firezone']['postgresql'][param] - end -end - -directory node['firezone']['postgresql']['log_directory'] do - owner node['firezone']['user'] - group node['firezone']['group'] - mode '0700' - recursive true -end - -if node['firezone']['postgresql']['enabled'] - enterprise_pg_cluster 'firezone' do - data_dir node['firezone']['postgresql']['data_directory'] - encoding 'UTF8' - end - - component_runit_service 'postgresql' do - package 'firezone' - control ['t'] - action :enable - subscribes :restart, 'enterprise_pg_cluster[firezone]' - end -else - runit_service 'postgresql' do - action :disable - end -end diff --git a/omnibus/cookbooks/firezone/recipes/setcap.rb b/omnibus/cookbooks/firezone/recipes/setcap.rb deleted file mode 100644 index f2f4839b6..000000000 --- a/omnibus/cookbooks/firezone/recipes/setcap.rb +++ /dev/null @@ -1,27 +0,0 @@ -# frozen_string_literal: true - -# Cookbook:: firezone -# Recipe:: setcap -# -# Copyright:: 2021, Firezone, All Rights Reserved. - -# Set capabilities for executables so they can be run without -# root privileges. - -include_recipe 'firezone::config' - -nft_path = "#{node['firezone']['install_directory']}/embedded/sbin/nft" - -file nft_path do - # Ensure phoenix app can control nftables - mode '0700' - owner node['firezone']['user'] - group node['firezone']['group'] - action :touch -end - -# setcap must be performed after the file resource above otherwise -# it gets reset -execute 'setcap_nft' do - command "setcap 'cap_net_admin,cap_net_raw+eip' #{nft_path}" -end diff --git a/omnibus/cookbooks/firezone/recipes/show_config.rb b/omnibus/cookbooks/firezone/recipes/show_config.rb deleted file mode 100644 index 2c185b159..000000000 --- a/omnibus/cookbooks/firezone/recipes/show_config.rb +++ /dev/null @@ -1,26 +0,0 @@ -# frozen_string_literal: true - -# -# Cookbook:: firezone -# Recipe:: show_config -# -# Copyright:: 2014 Chef Software, Inc. -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -# - -file_name = "#{node['firezone']['config_directory']}/firezone-running.json" - -raise 'Please run firezone-ctl reconfigure before attemping this command' unless File.exist?(file_name) - -puts File.read(file_name) diff --git a/omnibus/cookbooks/firezone/recipes/ssl.rb b/omnibus/cookbooks/firezone/recipes/ssl.rb deleted file mode 100644 index 330fa88ec..000000000 --- a/omnibus/cookbooks/firezone/recipes/ssl.rb +++ /dev/null @@ -1,103 +0,0 @@ -# frozen_string_literal: true - -# -# Cookbook:: firezone -# Recipe:: ssl -# -# Copyright:: 2014 Chef Software, Inc. -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -# - -include_recipe 'firezone::config' - -[node['firezone']['ssl']['directory'], - "#{node['firezone']['ssl']['directory']}/ca"].each do |dir| - directory dir do - owner node['firezone']['user'] - group node['firezone']['group'] - mode '0700' - end -end - -# Sets up SSL certificates. -# Creates a self-signed cert if none is provided. -firezone_ca_dir = File.join(node['firezone']['ssl']['directory'], 'ca') -ssl_dhparam = File.join(firezone_ca_dir, 'dhparams.pem') - -# Generate dhparams.pem for perfect forward secrecy -openssl_dhparam ssl_dhparam do - key_length 2048 - generator 2 - owner 'root' - group 'root' - mode '0644' -end - -node.default['firezone']['ssl']['ssl_dhparam'] ||= ssl_dhparam - -if node['firezone']['ssl']['certificate'] - # A certificate has been supplied - # Link the standard CA cert into our certs directory - link "#{node['firezone']['ssl']['directory']}/cacert.pem" do - to "#{node['firezone']['install_directory']}/embedded/ssl/certs/cacert.pem" - end -elsif node['firezone']['ssl']['acme']['enabled'] - # No certificate provided but acme enabled don't - # auto-generate and ensure acme directory is setup - directory "#{node['firezone']['var_directory']}/ssl/acme" do - owner 'root' - group 'root' - mode '0600' - end - -# No certificate has been supplied; generate one -else - host = URI.parse(node['firezone']['external_url']).host - ssl_keyfile = File.join(firezone_ca_dir, "#{host}.key") - ssl_crtfile = File.join(firezone_ca_dir, "#{host}.crt") - - openssl_x509_certificate ssl_crtfile do - common_name host - org node['firezone']['ssl']['company_name'] - org_unit node['firezone']['ssl']['organizational_unit_name'] - country node['firezone']['ssl']['country_name'] - key_length 2048 - expire 3650 - owner 'root' - group 'root' - mode '0644' - end - - node.default['firezone']['ssl']['certificate'] ||= ssl_crtfile - node.default['firezone']['ssl']['certificate_key'] ||= ssl_keyfile - - link "#{node['firezone']['ssl']['directory']}/cacert.pem" do - to ssl_crtfile - end -end - -# SAML certs -host = URI.parse(node['firezone']['external_url']).host -ssl_crtfile = File.join(node['firezone']['ssl']['directory'], 'saml.crt') -openssl_x509_certificate ssl_crtfile do - common_name host - org node['firezone']['ssl']['company_name'] - org_unit node['firezone']['ssl']['organizational_unit_name'] - country node['firezone']['ssl']['country_name'] - key_length 2048 - expire 3650 - owner 'root' - group 'root' - mode '0644' -end diff --git a/omnibus/cookbooks/firezone/recipes/stop_renewal.rb b/omnibus/cookbooks/firezone/recipes/stop_renewal.rb deleted file mode 100644 index a2e784456..000000000 --- a/omnibus/cookbooks/firezone/recipes/stop_renewal.rb +++ /dev/null @@ -1,21 +0,0 @@ -# frozen_string_literal: true - -# Cookbook:: firezone -# Recipe:: stop_renewal -# -# Copyright:: 2021, Firezone, All Rights Reserved. - -# Removes cronjob renewing certificates. Used during uninstall. - -include_recipe 'firezone::config' - -require 'mixlib/shellout' - -bin_path = "#{node['firezone']['install_directory']}/embedded/bin" - -# Remove cronjob (if cronjob doesn't exist no harm is done) -execute 'ACME remove cronjob' do - command <<~ACME - #{bin_path}/acme.sh --uninstall-cronjob - ACME -end diff --git a/omnibus/cookbooks/firezone/recipes/teardown.rb b/omnibus/cookbooks/firezone/recipes/teardown.rb deleted file mode 100644 index fd78ec6c6..000000000 --- a/omnibus/cookbooks/firezone/recipes/teardown.rb +++ /dev/null @@ -1,33 +0,0 @@ -# frozen_string_literal: true - -# Cookbook:: firezone -# Recipe:: teardown -# -# Copyright:: 2021, Firezone, All Rights Reserved. - -# Teardown all the network settings. Used during uninstall. - -include_recipe 'firezone::config' - -require 'mixlib/shellout' - -wg_interface = node['firezone']['wireguard']['interface_name'] -nft_path = "#{node['firezone']['install_directory']}/embedded/sbin/nft" - -# Delete wireguard interface if exists -wg_exists = Mixlib::ShellOut.new("ip link show dev #{wg_interface}") -wg_exists.run_command -if wg_exists.status.exitstatus.zero? - execute 'delete_wireguard_interface' do - command "ip link delete dev #{wg_interface}" - end -end - -# Delete firewall table -table_exists_cmd = Mixlib::ShellOut.new("#{nft_path} list table inet firezone") -table_exists_cmd.run_command -if table_exists_cmd.status.exitstatus.zero? - execute 'delete_firewall_table' do - command "#{nft_path} delete table inet firezone" - end -end diff --git a/omnibus/cookbooks/firezone/recipes/telemetry.rb b/omnibus/cookbooks/firezone/recipes/telemetry.rb deleted file mode 100644 index bb7ba1aae..000000000 --- a/omnibus/cookbooks/firezone/recipes/telemetry.rb +++ /dev/null @@ -1,26 +0,0 @@ -# frozen_string_literal: true - -# Cookbook:: firezone -# Recipe:: telemetry -# -# Copyright:: 2022, Firezone, All Rights Reserved. - -# Configure telemetry app-wide. - -include_recipe 'firezone::config' - -disable_telemetry_path = "#{node['firezone']['var_directory']}/.disable_telemetry" - -if node['firezone']['telemetry']['enabled'] == false - file 'disable_telemetry' do - path disable_telemetry_path - mode '0644' - user node['firezone']['user'] - group node['firezone']['group'] - end -else - file 'disable_telemetry' do - path disable_telemetry_path - action :delete - end -end diff --git a/omnibus/cookbooks/firezone/recipes/wireguard.rb b/omnibus/cookbooks/firezone/recipes/wireguard.rb deleted file mode 100644 index 9884989c1..000000000 --- a/omnibus/cookbooks/firezone/recipes/wireguard.rb +++ /dev/null @@ -1,29 +0,0 @@ -# frozen_string_literal: true - -# Cookbook:: firezone -# Recipe:: wireguard -# -# Copyright:: 2021, Firezone, All Rights Reserved. - -# Sets up service to manage WireGuard interface - -include_recipe 'firezone::config' - -directory node['firezone']['wireguard']['log_directory'] do - owner node['firezone']['user'] - group node['firezone']['group'] - mode '0700' - recursive true -end - -if node['firezone']['wireguard']['enabled'] - component_runit_service 'wireguard' do - package 'firezone' - action :enable - subscribes :restart, 'template[sv-wireguard-run]' - end -else - runit_service 'wireguard' do - action :disable - end -end diff --git a/omnibus/cookbooks/firezone/templates/firezone.rb.erb b/omnibus/cookbooks/firezone/templates/firezone.rb.erb deleted file mode 100644 index d2ec20e28..000000000 --- a/omnibus/cookbooks/firezone/templates/firezone.rb.erb +++ /dev/null @@ -1,3 +0,0 @@ -# This is the configuration file for Firezone. It lives in -# /etc/firezone/firezone.rb. The default configuration values are -# documented here and can be changed here. diff --git a/omnibus/cookbooks/firezone/templates/logrotate-rule.erb b/omnibus/cookbooks/firezone/templates/logrotate-rule.erb deleted file mode 100644 index efff8930b..000000000 --- a/omnibus/cookbooks/firezone/templates/logrotate-rule.erb +++ /dev/null @@ -1,15 +0,0 @@ -<%= @log_directory %>/*.log { - rotate <%= @log_rotation['num_to_keep'] %> - size <%= @log_rotation['file_maxbytes'] %> - create 644 <%= @owner || 'root' %> <%= @group || 'root' %> -<% if @postrotate -%> - delaycompress - sharedscripts - postrotate - <%= @postrotate %> - endscript -<% end -%> -<% if @copytruncate -%> - copytruncate -<% end -%> -} diff --git a/omnibus/cookbooks/firezone/templates/logrotate.conf.erb b/omnibus/cookbooks/firezone/templates/logrotate.conf.erb deleted file mode 100644 index 850ede5c8..000000000 --- a/omnibus/cookbooks/firezone/templates/logrotate.conf.erb +++ /dev/null @@ -1,4 +0,0 @@ -missingok -compress -notifempty -include <%= @var_directory %>/etc/logrotate.d diff --git a/omnibus/cookbooks/firezone/templates/logrotate.cron.erb b/omnibus/cookbooks/firezone/templates/logrotate.cron.erb deleted file mode 100644 index f1e805f65..000000000 --- a/omnibus/cookbooks/firezone/templates/logrotate.cron.erb +++ /dev/null @@ -1,6 +0,0 @@ -#!/bin/sh - -PATH=<%= @install_directory %>/embedded/sbin:$PATH - -command -v logrotate >/dev/null 2>&1 || exit 0 -nice -n 19 ionice -c3 logrotate <%= @var_directory %>/etc/logrotate.conf diff --git a/omnibus/cookbooks/firezone/templates/nginx.conf.erb b/omnibus/cookbooks/firezone/templates/nginx.conf.erb deleted file mode 100644 index 224e0327b..000000000 --- a/omnibus/cookbooks/firezone/templates/nginx.conf.erb +++ /dev/null @@ -1,101 +0,0 @@ -user <%= @nginx['user'] %><% if @nginx['user'] != @nginx['group'] %> <%= @nginx['group'] %><% end %>; -worker_processes <%= @nginx['worker_processes'] %>; -<% if @nginx['daemon_disable'] -%> -daemon off; -<% end -%> -<% if @nginx['worker_rlimit_nofile'] -%> -worker_rlimit_nofile <%= @nginx['worker_rlimit_nofile'] %>; -<% end -%> - -<% if @logging_enabled -%> - error_log <%= @nginx['log_dir'] %>/error.log; -<% else -%> - error_log /dev/null; -<% end -%> -pid <%= @nginx['pid'] %>; - -events { - worker_connections <%= @nginx['worker_connections'] %>; -<% if @nginx['multi_accept'] -%> - multi_accept on; -<% end -%> -<% if @nginx['event'] -%> - use <%= @nginx['event'] %>; -<% end -%> -} - -http { - <% if @nginx['log_x_forwarded_for'] -%> - log_format firezone '$http_x_forwarded_for - $remote_user [$time_iso8601] ' - <% else -%> - log_format firezone '$remote_addr - $remote_user [$time_iso8601] ' - <% end -%> - '"$request" $status $request_length "$request_time" $body_bytes_sent ' - '"$http_referer" "$http_user_agent"'; - - include <%= @nginx['dir'] %>/mime.types; - default_type application/octet-stream; - - <% if @logging_enabled -%> - <% unless @nginx['disable_access_log'] -%> - access_log <%= @nginx['log_dir'] %>/access.log firezone; - <% end %> - <% end -%> - - server_tokens off; - add_header X-Clacks-Overhead "GNU Terry Pratchett"; - - sendfile <%= @nginx['sendfile'] %>; - tcp_nopush on; - tcp_nodelay on; - - <% if @nginx['keepalive'] == "on" %> - keepalive_timeout <%= @nginx['keepalive_timeout'] %>; - <% end %> - - gzip <%= @nginx['gzip'] %>; - <% if @nginx['gzip'] == "on" %> - gzip_http_version <%= @nginx['gzip_http_version'] %>; - gzip_comp_level <%= @nginx['gzip_comp_level'] %>; - gzip_proxied <%= @nginx['gzip_proxied'] %>; - gzip_vary <%= @nginx['gzip_vary'] %>; - <% if @nginx['gzip_buffers'] -%> - gzip_buffers <%= @nginx['gzip_buffers'] %>; - <% end -%> - gzip_types <%= @nginx['gzip_types'].join(' ') %>; - gzip_min_length 1000; - gzip_disable "MSIE [1-6]\."; - <% end %> - - server_names_hash_bucket_size <%= @nginx['server_names_hash_bucket_size'] %>; - types_hash_max_size <%= @nginx['types_hash_max_size'] %>; - types_hash_bucket_size <%= @nginx['types_hash_bucket_size'] %>; - <% if @nginx['proxy_read_timeout'] -%> - proxy_read_timeout <%= @nginx['proxy_read_timeout'] %>; - <% end -%> - <% if @nginx['client_body_buffer_size'] -%> - client_body_buffer_size <%= @nginx['client_body_buffer_size'] %>; - <% end -%> - <% if @nginx['client_max_body_size'] -%> - client_max_body_size <%= @nginx['client_max_body_size'] %>; - <% end -%> - - <% if @nginx['enable_rate_limiting'] -%> - limit_req_zone $binary_remote_addr zone=<%= @nginx['rate_limiting_zone_name'] %>:<%= @nginx['rate_limiting_backoff'] %> rate=<%= @nginx['rate_limit'] %>; - - <% end -%> - - # Security headers - add_header X-XSS-Protection "1; mode=block" always; - add_header X-Content-Type-Options "nosniff" always; - add_header Referrer-Policy "no-referrer-when-downgrade" always; - add_header Content-Security-Policy "default-src 'self' ws: wss: http: https: data: blob: 'unsafe-inline'; frame-ancestors 'self';" always; - add_header Permissions-Policy "interest-cohort=()" always; - <% if @nginx['hsts_header']['enabled'] -%> - add_header Strict-Transport-Security "max-age=<%= @nginx['hsts_header']['max_age'] %>; <%= 'includeSubDomains' if @nginx['hsts_header']['include_subdomains'] %>" always; - <% end -%> - - include <%= @nginx['dir'] %>/conf.d/*.conf; - include <%= @nginx['dir'] %>/sites-enabled/*; - include <%= @nginx['dir'] %>/redirect.conf; -} diff --git a/omnibus/cookbooks/firezone/templates/pg_hba.conf.erb b/omnibus/cookbooks/firezone/templates/pg_hba.conf.erb deleted file mode 100644 index bdcbe8fbc..000000000 --- a/omnibus/cookbooks/firezone/templates/pg_hba.conf.erb +++ /dev/null @@ -1,73 +0,0 @@ -# PostgreSQL Client Authentication Configuration File -# =================================================== -# -# Refer to the "Client Authentication" section in the -# PostgreSQL documentation for a complete description -# of this file. A short synopsis follows. -# -# This file controls: which hosts are allowed to connect, how clients -# are authenticated, which PostgreSQL user names they can use, which -# databases they can access. Records take one of these forms: -# -# local DATABASE USER METHOD [OPTION] -# host DATABASE USER CIDR-ADDRESS METHOD [OPTION] -# hostssl DATABASE USER CIDR-ADDRESS METHOD [OPTION] -# hostnossl DATABASE USER CIDR-ADDRESS METHOD [OPTION] -# -# (The uppercase items must be replaced by actual values.) -# -# The first field is the connection type: "local" is a Unix-domain socket, -# "host" is either a plain or SSL-encrypted TCP/IP socket, "hostssl" is an -# SSL-encrypted TCP/IP socket, and "hostnossl" is a plain TCP/IP socket. -# -# DATABASE can be "all", "sameuser", "samerole", a database name, or -# a comma-separated list thereof. -# -# USER can be "all", a user name, a group name prefixed with "+", or -# a comma-separated list thereof. In both the DATABASE and USER fields -# you can also write a file name prefixed with "@" to include names from -# a separate file. -# -# CIDR-ADDRESS specifies the set of hosts the record matches. -# It is made up of an IP address and a CIDR mask that is an integer -# (between 0 and 32 (IPv4) or 128 (IPv6) inclusive) that specifies -# the number of significant bits in the mask. Alternatively, you can write -# an IP address and netmask in separate columns to specify the set of hosts. -# -# METHOD can be "trust", "reject", "md5", "crypt", "password", "gss", "sspi", -# "krb5", "ident", "pam" or "ldap". Note that "password" sends passwords -# in clear text; "md5" is preferred since it sends encrypted passwords. -# -# OPTION is the ident map or the name of the PAM service, depending on METHOD. -# -# Database and user names containing spaces, commas, quotes and other special -# characters must be quoted. Quoting one of the keywords "all", "sameuser" or -# "samerole" makes the name lose its special character, and just match a -# database or username with that name. -# -# This file is read on server startup and when the postmaster receives -# a SIGHUP signal. If you edit the file on a running system, you have -# to SIGHUP the postmaster for the changes to take effect. You can use -# "pg_ctl reload" to do that. - -# Put your actual configuration here -# ---------------------------------- -# -# If you want to allow non-local connections, you need to add more -# "host" records. In that case you will also need to make PostgreSQL listen -# on a non-local interface via the listen_addresses configuration parameter, -# or via the -i or -h command line switches. -# - - -# TYPE DATABASE USER CIDR-ADDRESS METHOD - -# "local" is for Unix domain socket connections only -local all <%= node['firezone']['postgresql']['username'] %> peer - -host all <%= node['firezone']['postgresql']['username'] %> 127.0.0.1/32 trust -host all <%= node['firezone']['postgresql']['username'] %> ::1/128 trust - -<% node['firezone']['postgresql']['md5_auth_cidr_addresses'].each do |cidr| %> -host all all <%= cidr %> md5 -<% end %> diff --git a/omnibus/cookbooks/firezone/templates/phoenix.nginx.conf.erb b/omnibus/cookbooks/firezone/templates/phoenix.nginx.conf.erb deleted file mode 100644 index 211782672..000000000 --- a/omnibus/cookbooks/firezone/templates/phoenix.nginx.conf.erb +++ /dev/null @@ -1,133 +0,0 @@ -# Nginx configuration for Firezone's Phoenix app -# -# Generated by Chef - -upstream phoenix { - server <%= @phoenix['listen_address'] %>:<%= @phoenix['port'] %>; -} - -<% if @nginx['cache']['enabled'] -%> -proxy_cache_path <%= @nginx['cache']['directory'] %>/firezone levels=1:2 keys_zone=firezone-cache:512m max_size=1000m inactive=600m; -proxy_temp_path <%= @nginx['cache']['directory'] %>/tmp; - -log_format cache '$remote_addr - [$time_local] "$request" $upstream_cache_status $upstream_response_time $upstream_status'; -<% end %> - -server { - listen <%= @nginx['ssl_port'] %> default_server ssl; - <% if @nginx['ipv6'] -%> - listen [::]:<%= @nginx['ssl_port'] %> default_server ssl; - <% end -%> - - server_name <%= @fqdn %>; - - <% if @acme['enabled'] && !@ssl['certificate'] -%> - ssl_certificate <%= @acme['certificate'] %>; - ssl_certificate_key <%= @acme['certificate_key'] %>; - <% else -%> - ssl_certificate <%= @ssl['certificate'] %>; - ssl_certificate_key <%= @ssl['certificate_key'] %>; - <% end %> - ssl_dhparam <%= @ssl['ssl_dhparam'] %>; - ssl_prefer_server_ciphers on; - ssl_ciphers <%= @fips_enabled ? @ssl['fips_ciphers'] : @ssl['ciphers'] %>; - ssl_protocols <%= @ssl['protocols'] %>; - ssl_session_cache <%= @ssl['session_cache'] %>; - ssl_session_timeout <%= @ssl['session_timeout'] %>; - -<% if @nginx['redirect_to_canonical'] -%> - set $redirect_to_canonical 0; - - # Redirect anything that isn't an ip address (for ELB checks) or the - # canonical server name to <%= @fqdn %> - if ($host !~* "^(<%= @fqdn.gsub('.', '\.') %>|[0-9.]+)$") { - set $redirect_to_canonical H; - } - - if ($redirect_to_canonical = H) { - return 301 https://<%= @fqdn %>$request_uri; - } -<% end -%> - -<% if @logging_enabled -%> - <% if @nginx['cache']['enabled'] -%> - access_log <%= @nginx['log_directory'] %>/cache.log cache; - <% end -%> -<% end -%> - - location ~ /sitemap\d*.xml.gz { - root <%= @app_directory %>/public; - break; - } - - location ~ ^/(assets|system)/ { - root <%= @app_directory %>/public; - expires 1y; - add_header Cache-Control public; - add_header ETag ""; - break; - } - - location ~ ^/curry/ { - return 410; - } - -<% if @nginx['cache']['enabled'] -%> - # TODO: Is this useful to Firezone? - location ~ ^/api/v1/cookbooks/.*/versions/.*(/download)?$ { - proxy_set_header HOST $host; - proxy_set_header X-Real-IP $remote_addr; - proxy_set_header X-Forwarded-For $remote_addr; - proxy_set_header X-Forwarded-Proto $http_x_forwarded_proto; - proxy_pass http://phoenix; - proxy_redirect off; - - proxy_ignore_headers Set-Cookie Cache-Control; - proxy_buffering on; - - proxy_cache firezone-cache; - proxy_cache_valid 200 302 240m; - proxy_cache_valid any 5m; - expires 240m; - - # to serve gzipped text and json responses - gzip on; - gzip_proxied expired no-cache no-store private auth; - } -<% end -%> - - location ~ ^/live { - proxy_pass http://phoenix; - proxy_http_version 1.1; - proxy_set_header Host $host; - proxy_set_header X-Forwarded-For $remote_addr; - proxy_set_header X-Forwarded-Proto https; - proxy_set_header Upgrade $http_upgrade; - proxy_set_header Connection "upgrade"; - } - - location ~ ^/socket { - proxy_pass http://phoenix; - proxy_http_version 1.1; - proxy_set_header Host $host; - proxy_set_header X-Forwarded-For $remote_addr; - proxy_set_header X-Forwarded-Proto https; - proxy_set_header Upgrade $http_upgrade; - proxy_set_header Connection "upgrade"; - } - - location / { - proxy_set_header HOST $host; - proxy_set_header X-Real-IP $remote_addr; - proxy_set_header X-Forwarded-For $remote_addr; - proxy_set_header X-Forwarded-Proto https; - proxy_pass http://phoenix; - proxy_redirect off; - - # to serve gzipped text and json responses - gzip on; - gzip_min_length 1000; - gzip_proxied expired no-cache no-store private auth; - gzip_types text/plain application/json; - } -} diff --git a/omnibus/cookbooks/firezone/templates/postgresql.conf.erb b/omnibus/cookbooks/firezone/templates/postgresql.conf.erb deleted file mode 100644 index b24906dd5..000000000 --- a/omnibus/cookbooks/firezone/templates/postgresql.conf.erb +++ /dev/null @@ -1,22 +0,0 @@ -listen_addresses = '<%= node['firezone']['postgresql']['listen_address'] %>' # what IP address(es) to listen on; -port = <%= node['firezone']['postgresql']['port'] %> # (change requires restart) -max_connections = <%= node['firezone']['postgresql']['max_connections'] %> # (change requires restart) -shared_buffers = <%= node['firezone']['postgresql']['shared_buffers'] %> # min 128kB -work_mem = <%= node['firezone']['postgresql']['work_mem'] %> # min 64kB - -# XXX: Has been deprecated. Update for Postgresql 13.3 -# checkpoint_segments = <%= node['firezone']['postgresql']['checkpoint_segments'] %> # in logfile segments, min 1, 16MB each, default 3 -checkpoint_timeout = <%= node['firezone']['postgresql']['checkpoint_timeout'] %> # range 30s-1h, default 5min -checkpoint_completion_target = <%= node['firezone']['postgresql']['checkpoint_completion_target'] %> # checkpoint target duration, 0.0 - 1.0, default 0.5 -checkpoint_warning = <%= node['firezone']['postgresql']['checkpoint_warning'] %> # 0 disables, default 30s - -effective_cache_size = <%= node['firezone']['postgresql']['effective_cache_size'] %> # Default 128MB - -datestyle = 'iso, mdy' - -lc_messages = 'C' # locale for system error message -lc_monetary = 'C' # locale for monetary formatting -lc_numeric = 'C' # locale for number formatting -lc_time = 'C' # locale for time formatting - -default_text_search_config = 'pg_catalog.english' diff --git a/omnibus/cookbooks/firezone/templates/redirect.conf.erb b/omnibus/cookbooks/firezone/templates/redirect.conf.erb deleted file mode 100644 index 1ffd36471..000000000 --- a/omnibus/cookbooks/firezone/templates/redirect.conf.erb +++ /dev/null @@ -1,18 +0,0 @@ -<% if @acme['enabled'] -%> -server { - listen 80 default_server; - <% if @ipv6 -%> - listen [::]:80 default_server; - <% end -%> - server_name <%= @server_name %>; - - # Needed for ACME requests - location /.well-known/acme-challenge/ { - alias <%= @acme_www_root %>/.well-known/acme-challenge/; - } - - location ^~ ^/.well-known/acme-challenge/ { - return 301 https://<%= @server_name %>$request_uri; - } -} -<% end -%> diff --git a/omnibus/cookbooks/firezone/templates/ssl-signing.conf.erb b/omnibus/cookbooks/firezone/templates/ssl-signing.conf.erb deleted file mode 100644 index 6d846b790..000000000 --- a/omnibus/cookbooks/firezone/templates/ssl-signing.conf.erb +++ /dev/null @@ -1,12 +0,0 @@ -[ req ] -distinguished_name = req_distinguished_name -prompt = no - -[ req_distinguished_name ] -C = <%= node['firezone']['ssl']['country_name'] %> -ST = <%= node['firezone']['ssl']['state_name'] %> -L = <%= node['firezone']['ssl']['locality_name'] %> -O = <%= node['firezone']['ssl']['company_name'] %> -OU = <%= node['firezone']['ssl']['organizational_unit_name'] %> -CN = <%= URI.parse(node['firezone']['external_url']).host %> -emailAddress = <%= node['firezone']['ssl']['email_address'] %> diff --git a/omnibus/cookbooks/firezone/templates/sv-nginx-log-run.erb b/omnibus/cookbooks/firezone/templates/sv-nginx-log-run.erb deleted file mode 100644 index a85de9411..000000000 --- a/omnibus/cookbooks/firezone/templates/sv-nginx-log-run.erb +++ /dev/null @@ -1,3 +0,0 @@ -#!/bin/sh -exec <%= node['runit']['svlogd_bin'] %> \ - -tt <%= node['firezone']['nginx']['log_directory'] %> diff --git a/omnibus/cookbooks/firezone/templates/sv-nginx-run.erb b/omnibus/cookbooks/firezone/templates/sv-nginx-run.erb deleted file mode 100644 index 2390d00a6..000000000 --- a/omnibus/cookbooks/firezone/templates/sv-nginx-run.erb +++ /dev/null @@ -1,8 +0,0 @@ -#!/bin/sh -exec 2>&1 -<%= 'export OPENSSL_FIPS=1' if node['firezone']['fips_enabled'] == true %> - -exec <%= node['runit']['chpst_bin'] %> \ - -P \ - <%= node['firezone']['install_directory'] %>/embedded/sbin/nginx \ - -c <%= node['firezone']['nginx']['directory'] %>/nginx.conf <%= '> /dev/null 2>&1' unless node['firezone']['logging']['enabled'] %> diff --git a/omnibus/cookbooks/firezone/templates/sv-phoenix-finish.erb b/omnibus/cookbooks/firezone/templates/sv-phoenix-finish.erb deleted file mode 100644 index f94c69d49..000000000 --- a/omnibus/cookbooks/firezone/templates/sv-phoenix-finish.erb +++ /dev/null @@ -1,46 +0,0 @@ -#!/bin/sh -exec 2>&1 - -capture () { - if type curl > /dev/null; then - if [ -e /var/opt/firezone/cache/telemetry_id ]; then - telemetry_id=`cat /var/opt/firezone/cache/telemetry_id` - if [ ! -z "$telemetry_id" ]; then - curl -s -XPOST \ - -m 5 \ - -H 'Content-Type: application/json' \ - -d "{ - \"api_key\": \"phc_ubuPhiqqjMdedpmbWpG2Ak3axqv5eMVhFDNBaXl9UZK\", - \"event\": \"fz_http_crash\", - \"properties\": { - \"distinct_id\": \"$telemetry_id\" - } - }" \ - https://t.firez.one/capture/ > /dev/null - fi - fi - fi -} - -if [ $1 -eq "1" ]; then - if [ ! -e /var/opt/firezone/.disable_telemetry ]; then - capture || true - fi - - enabled=<%=node['firezone']['phoenix']['crash_detection']['enabled']%> - if $enabled && [ -e count ]; then - count=`cat count` - if [ $count -eq "5" ]; then - rm -f count - echo "Firezone detected a service crash loop. Taking service down. For support please email support@firezone.dev and include a copy of these crash logs." - echo 'd' > supervise/control - else - new_count=$((count+1)) - echo $new_count > count - fi - else - echo '1' > count - fi -else - rm -f count -fi diff --git a/omnibus/cookbooks/firezone/templates/sv-phoenix-log-run.erb b/omnibus/cookbooks/firezone/templates/sv-phoenix-log-run.erb deleted file mode 100644 index 3746e01d2..000000000 --- a/omnibus/cookbooks/firezone/templates/sv-phoenix-log-run.erb +++ /dev/null @@ -1,3 +0,0 @@ -#!/bin/sh -exec <%= node['runit']['svlogd_bin'] %> \ - -tt <%= node['firezone']['phoenix']['log_directory'] %> diff --git a/omnibus/cookbooks/firezone/templates/sv-phoenix-run.erb b/omnibus/cookbooks/firezone/templates/sv-phoenix-run.erb deleted file mode 100644 index 1a9d6d498..000000000 --- a/omnibus/cookbooks/firezone/templates/sv-phoenix-run.erb +++ /dev/null @@ -1,18 +0,0 @@ -#!/bin/sh -exec 2>&1 - -export PATH=<%= node['firezone']['install_directory'] %>/embedded/bin:$PATH -export LD_LIBRARY_PATH=<%= node['firezone']['install_directory'] %>/embedded/lib -export DIR=<%= node['firezone']['app_directory'] %> -export HOME=$DIR -<%= "export OPENSSL_FIPS=1" if node['firezone']['fips_enabled'] == true %> -<%= Firezone::Config.locale_variables %> - -cd $DIR - -exec <%= node['runit']['chpst_bin'] %> \ - -e <%= node['firezone']['install_directory'] %>/sv/phoenix/env \ - -P \ - -U <%= node['firezone']['user'] %>:<%= node['firezone']['group'] %> \ - -u <%= node['firezone']['user'] %>:<%= node['firezone']['group'] %> \ - bin/firezone start <%= '> /dev/null 2>&1' unless node['firezone']['logging']['enabled'] %> diff --git a/omnibus/cookbooks/firezone/templates/sv-phoenix-t.erb b/omnibus/cookbooks/firezone/templates/sv-phoenix-t.erb deleted file mode 100644 index 769820897..000000000 --- a/omnibus/cookbooks/firezone/templates/sv-phoenix-t.erb +++ /dev/null @@ -1,5 +0,0 @@ -#!/bin/sh -<% if node['firezone']['logging']['enabled'] -%> - echo "received TERM from runit, forcing quit" -<% end -%> -<%= node['runit']['sv_bin'] %> kill phoenix diff --git a/omnibus/cookbooks/firezone/templates/sv-postgresql-log-run.erb b/omnibus/cookbooks/firezone/templates/sv-postgresql-log-run.erb deleted file mode 100644 index 654254c6a..000000000 --- a/omnibus/cookbooks/firezone/templates/sv-postgresql-log-run.erb +++ /dev/null @@ -1,3 +0,0 @@ -#!/bin/sh -exec <%= node['runit']['svlogd_bin'] %> \ - -tt <%= node['firezone']['postgresql']['log_directory'] %> diff --git a/omnibus/cookbooks/firezone/templates/sv-postgresql-run.erb b/omnibus/cookbooks/firezone/templates/sv-postgresql-run.erb deleted file mode 100644 index ff39c45a2..000000000 --- a/omnibus/cookbooks/firezone/templates/sv-postgresql-run.erb +++ /dev/null @@ -1,8 +0,0 @@ -#!/bin/sh -exec 2>&1 -exec <%= node['runit']['chpst_bin'] %> \ - -P \ - -U <%= node['firezone']['postgresql']['username'] %> \ - -u <%= node['firezone']['postgresql']['username'] %> \ - <%= node['firezone']['install_directory']%>/embedded/bin/postgres \ - -D <%= node['firezone']['postgresql']['data_directory'] %> <%= '> /dev/null 2>&1' unless node['firezone']['logging']['enabled'] %> diff --git a/omnibus/cookbooks/firezone/templates/sv-postgresql-t.erb b/omnibus/cookbooks/firezone/templates/sv-postgresql-t.erb deleted file mode 100644 index 7e97ba6a0..000000000 --- a/omnibus/cookbooks/firezone/templates/sv-postgresql-t.erb +++ /dev/null @@ -1,5 +0,0 @@ -#!/bin/sh -<% if node['firezone']['logging']['enabled'] -%> - echo "received TERM from runit, sending INT instead to force quit connections" -<% end -%> -<%= node['runit']['sv_bin'] %> interrupt postgresql diff --git a/omnibus/cookbooks/firezone/templates/sv-wireguard-log-run.erb b/omnibus/cookbooks/firezone/templates/sv-wireguard-log-run.erb deleted file mode 100644 index b19294b89..000000000 --- a/omnibus/cookbooks/firezone/templates/sv-wireguard-log-run.erb +++ /dev/null @@ -1,3 +0,0 @@ -#!/bin/sh -exec <%= node['runit']['svlogd_bin'] %> \ - -tt <%= node['firezone']['wireguard']['log_directory'] %> diff --git a/omnibus/cookbooks/firezone/templates/sv-wireguard-run.erb b/omnibus/cookbooks/firezone/templates/sv-wireguard-run.erb deleted file mode 100644 index 49884c863..000000000 --- a/omnibus/cookbooks/firezone/templates/sv-wireguard-run.erb +++ /dev/null @@ -1,18 +0,0 @@ -#!/bin/sh -exec 2>&1 -<%= "export OPENSSL_FIPS=1" if node['firezone']['fips_enabled'] == true %> - -export WIREGUARD_INTERFACE_NAME=<%= node['firezone']['wireguard']['interface_name'] %> -export WIREGUARD_IPV4_ENABLED=<%= node['firezone']['wireguard']['ipv4']['enabled'] %> -export WIREGUARD_IPV4_ADDRESS=<%= node['firezone']['wireguard']['ipv4']['address'] %> -export WIREGUARD_IPV4_NETWORK=<%= node['firezone']['wireguard']['ipv4']['network'] %> -export WIREGUARD_IPV6_ENABLED=<%= node['firezone']['wireguard']['ipv6']['enabled'] %> -export WIREGUARD_IPV6_ADDRESS=<%= node['firezone']['wireguard']['ipv6']['address'] %> -export WIREGUARD_IPV6_NETWORK=<%= node['firezone']['wireguard']['ipv6']['network'] %> -export WIREGUARD_INTERFACE_MTU=<%= node['firezone']['wireguard']['mtu'] %> -export WIREGUARD_LISTEN_PORT=<%= node['firezone']['wireguard']['port'] %> -export LOGGING_ENABLED=<%= node['firezone']['logging']['enabled'] %> - -exec <%= node['runit']['chpst_bin'] %> \ - -P \ - <%= node['firezone']['install_directory'] %>/embedded/bin/wireguard <%= '> /dev/null 2>&1' unless node['firezone']['logging']['enabled'] %> diff --git a/omnibus/cookbooks/firezone/test/integration/default/default_test.rb b/omnibus/cookbooks/firezone/test/integration/default/default_test.rb deleted file mode 100644 index cade36db0..000000000 --- a/omnibus/cookbooks/firezone/test/integration/default/default_test.rb +++ /dev/null @@ -1,18 +0,0 @@ -# frozen_string_literal: true - -# Chef InSpec test for recipe firezone::default - -# The Chef InSpec reference, with examples and extensive documentation, can be -# found at https://docs.chef.io/inspec/resources/ - -unless os.windows? - # This is an example test, replace with your own test. - describe user('root'), :skip do - it { should exist } - end -end - -# This is an example test, replace it with your own test. -describe port(80), :skip do - it { should_not be_listening } -end diff --git a/omnibus/files/firezone-scripts/symlink_ctl_cmds b/omnibus/files/firezone-scripts/symlink_ctl_cmds deleted file mode 100755 index 813c950fa..000000000 --- a/omnibus/files/firezone-scripts/symlink_ctl_cmds +++ /dev/null @@ -1,26 +0,0 @@ -#!/bin/bash -# -# Symlink the ctl commands -DEST_DIR=${1:-/opt/firezone} - -usr_bin_symlinks=( - "${DEST_DIR}/bin/firezone-ctl" -) - -error_exit() -{ - echo "${1:-"Unknown Error"}" 1>&2 - exit 1 -} - -create_symlinks() -{ - for symlink in "${usr_bin_symlinks[@]}" - do - if [ -f $symlink ]; then - ln -sf $symlink /usr/bin || error_exit "Failed to create symlinks in /usr/bin" - fi - done -} - -create_symlinks diff --git a/omnibus/files/firezone-scripts/wireguard b/omnibus/files/firezone-scripts/wireguard deleted file mode 100755 index de1466817..000000000 --- a/omnibus/files/firezone-scripts/wireguard +++ /dev/null @@ -1,56 +0,0 @@ -#!/bin/sh - -# Sets up the wireguard interface and begins logging - -error_exit() -{ - echo "${1:-"Unknown Error"}" 1>&2 - exit 1 -} - -setup_interface() -{ - ip link show dev ${WIREGUARD_INTERFACE_NAME} - if [ $? -ne 0 ]; then - ip link add ${WIREGUARD_INTERFACE_NAME} type wireguard - fi - - if [ $WIREGUARD_IPV4_ENABLED = "true" ]; then - ip address replace ${WIREGUARD_IPV4_ADDRESS} dev ${WIREGUARD_INTERFACE_NAME} - fi - if [ $WIREGUARD_IPV6_ENABLED = "true" ]; then - ip -6 address replace ${WIREGUARD_IPV6_ADDRESS} dev ${WIREGUARD_INTERFACE_NAME} - fi - ip link set mtu ${WIREGUARD_INTERFACE_MTU} up dev ${WIREGUARD_INTERFACE_NAME} -} - -add_routes() -{ - if [ $WIREGUARD_IPV4_ENABLED = "true" ]; then - ip route add ${WIREGUARD_IPV4_NETWORK} dev ${WIREGUARD_INTERFACE_NAME} - fi - if [ $WIREGUARD_IPV6_ENABLED = "true" ]; then - ip -6 route add ${WIREGUARD_IPV6_NETWORK} dev ${WIREGUARD_INTERFACE_NAME} - fi -} - -main() -{ - if [ $LOGGING_ENABLED = "true" ]; then - echo 'Enabling WireGuard debugging support...' - echo module wireguard +p > /sys/kernel/debug/dynamic_debug/control - if [ $? -eq 0 ]; then - echo 'WireGuard debugging enabled. Starting dmesg...' - dmesg -wT | grep "wireguard: ${WIREGUARD_INTERFACE_NAME}:" - else - echo 'There was an issue enabling WireGuard debugging. Twiddling my thumbs...' - tail -f /dev/null - fi - else - tail -f /dev/null - fi -} - -setup_interface -add_routes -main diff --git a/omnibus/omnibus.rb b/omnibus/omnibus.rb deleted file mode 100644 index 51b8ca05d..000000000 --- a/omnibus/omnibus.rb +++ /dev/null @@ -1,66 +0,0 @@ -# frozen_string_literal: true - -# This file is used to configure the firezone project. It contains -# some minimal configuration examples for working with Omnibus. For a full list -# of configurable options, please see the documentation for +omnibus/config.rb+. -# - -# Build internally -# ------------------------------ -# By default, Omnibus uses system folders (like +/var+ and +/opt+) to build and -# cache components. If you would to build everything internally, you can -# uncomment the following options. This will prevent the need for root -# permissions in most cases. -# -# Uncomment this line to change the default base directory to "local" -# ------------------------------------------------------------------- -if ENV['CI'] - base_dir('/opt/runner/omnibus-local') -else - base_dir('/tmp/omnibus-local') -end -# -# Alternatively you can tune the individual values -# ------------------------------------------------ -# cache_dir './local/omnibus/cache' -# git_cache_dir './local/omnibus/cache/git_cache' -# source_dir './local/omnibus/src' -# build_dir './local/omnibus/build' -# package_dir './local/omnibus/pkg' -# package_tmp './local/omnibus/pkg-tmp' - -# Disable git caching -# ------------------------------ -# use_git_caching false - -# Don't append timestamp for builds -append_timestamp false - -# Enable S3 asset caching -# ------------------------------ -# use_s3_caching true -# s3_access_key ENV['AWS_ACCESS_KEY_ID'] -# s3_secret_key ENV['AWS_SECRET_ACCESS_KEY'] -# s3_profile ENV['AWS_S3_PROFILE'] -# s3_iam_role_arn ENV['S3_IAM_ROLE_ARN'] -# s3_bucket ENV['AWS_S3_BUCKET'] - -# Customize compiler bits -# ------------------------------ -# solaris_compiler 'gcc' -# build_retries 5 -# fetcher_read_timeout 120 -# fetcher_retries 5 - -# Load additional software -# ------------------------------ -# software_gems ['omnibus-software', 'my-company-software'] -# local_software_dirs ['/path/to/local/software'] - -# Windows architecture defaults -# ------------------------------ -if %w[x86 x64].include?((ENV['OMNIBUS_WINDOWS_ARCH'] || '').downcase) - windows_arch(ENV['OMNIBUS_WINDOWS_ARCH'].downcase.to_sym) -else - windows_arch(:x86) -end diff --git a/omnibus/package-scripts/firezone/postinst b/omnibus/package-scripts/firezone/postinst deleted file mode 100755 index fcd952d56..000000000 --- a/omnibus/package-scripts/firezone/postinst +++ /dev/null @@ -1,58 +0,0 @@ -#!/bin/sh - -# Perform necessary post-installation steps - -capture () { - if type curl > /dev/null; then - if [ -e /var/opt/firezone/cache/telemetry_id ]; then - telemetry_id=`cat /var/opt/firezone/cache/telemetry_id` - if [ ! -z "$telemetry_id" ]; then - curl -s -XPOST \ - -m 5 \ - -H 'Content-Type: application/json' \ - -d "{ - \"api_key\": \"phc_ubuPhiqqjMdedpmbWpG2Ak3axqv5eMVhFDNBaXl9UZK\", - \"event\": \"postinst\", - \"properties\": { - \"distinct_id\": \"$telemetry_id\" - } - }" \ - https://t.firez.one/capture/ > /dev/null - fi - fi - fi -} -if [ ! -e /var/opt/firezone/.disable_telemetry ]; then - capture || true -fi - -# Symlink ctl commands -DEST_DIR=/opt/firezone - -if [ -e ${DEST_DIR}/embedded/bin/symlink_ctl_cmds ]; then - ${DEST_DIR}/embedded/bin/symlink_ctl_cmds -fi - -if tput bold; then - bold=$(tput bold) -else - bold='' -fi -if tput sgr0; then - normal=$(tput sgr0) -else - normal='' -fi - -echo $bold -echo "Please see our upgrade guide for any version notes that apply:" -echo -echo "=> https://docs.firezone.dev/administer/upgrade/?utm_source=product" -echo -echo -echo "Heads up! Firezone 0.7.x will be the last release to support Omnibus." -echo "Firezone 0.8 and above will support containerized deployments only." -echo "Read more about the transition in our migration guide:" -echo -echo "=> https://docs.firezone.dev/administer/migrate/?utm_source=product" -echo $normal diff --git a/omnibus/package-scripts/firezone/postrm b/omnibus/package-scripts/firezone/postrm deleted file mode 100755 index 2df65cfa7..000000000 --- a/omnibus/package-scripts/firezone/postrm +++ /dev/null @@ -1,34 +0,0 @@ -#!/bin/sh -set -e -# -# Perform necessary firezone removal steps -# after package is uninstalled. -# - -capture () { - if type curl > /dev/null; then - if [ -e /var/opt/firezone/cache/telemetry_id ]; then - telemetry_id=`cat /var/opt/firezone/cache/telemetry_id` - if [ ! -z "$telemetry_id" ]; then - curl -s -XPOST \ - -m 5 \ - -H 'Content-Type: application/json' \ - -d "{ - \"api_key\": \"phc_ubuPhiqqjMdedpmbWpG2Ak3axqv5eMVhFDNBaXl9UZK\", - \"event\": \"postrm\", - \"properties\": { - \"distinct_id\": \"$telemetry_id\" - } - }" \ - https://t.firez.one/capture/ > /dev/null - fi - fi - fi -} -if [ ! -e /var/opt/firezone/.disable_telemetry ]; then - capture || true -fi - -echo "firezone has been uninstalled!" - -exit 0 diff --git a/omnibus/package-scripts/firezone/preinst b/omnibus/package-scripts/firezone/preinst deleted file mode 100755 index 61349e73e..000000000 --- a/omnibus/package-scripts/firezone/preinst +++ /dev/null @@ -1,73 +0,0 @@ -#!/bin/sh -set -e -# -# Perform necessary firezone setup steps -# before package is installed. -# - -kernelCheck() { - major=`uname -r | cut -d'.' -f1` - if [ "$major" -lt "5" ]; then - echo "################################################################################" - echo "# ERROR: Kernel version `uname -r` is not supported. Firezone requires #" - echo "# kernel >= 5 or higher. See our listed of supported platforms for more #" - echo "# information: https://docs.firezone.dev/deploy/supported-platforms/ #" - echo "################################################################################" - exit - fi -} - -configCheck() { - config_file='/etc/firezone/firezone.rb' - - if tput setaf 1; then - error=$(tput setaf 1) - else - error='' - fi - if tput sgr0; then - normal=$(tput sgr0) - else - normal='' - fi - - if test -f $config_file && grep -q "^\s*default\['firezone'\]\['authentication'\]\['\(google\|okta\)'\]\['enabled'\]\s*=\s*true" $config_file ; then - echo "${error}ERROR: Firezone 0.5+ disables support for pre-configured Okta and Google OAuth2 providers!${normal}" - echo "Please see our transition guide to move to a generic OIDC config: https://docs.firezone.dev/administer/upgrade#upgrading-from--050-to--050" - exit 1 - fi - - if test -f $config_file && grep -q "^\s*default\['firezone'\]\['nginx'\]\['force_ssl'\]\s*=\s*false" $config_file ; then - echo "${error}ERROR: Firezone 0.5+ removes support for disabling SSL redirect!${normal}" - echo "Instead, disable Nginx and point your SSL-terminating proxy directly to the phoenix app on port 13000. See the docs for more information: https://docs.firezone.dev/deploy/reverse-proxies" - exit 1 - fi -} - -capture () { - if type curl > /dev/null; then - if [ -e /var/opt/firezone/cache/telemetry_id ]; then - telemetry_id=`cat /var/opt/firezone/cache/telemetry_id` - if [ ! -z "$telemetry_id" ]; then - curl -s -XPOST \ - -m 5 \ - -H 'Content-Type: application/json' \ - -d "{ - \"api_key\": \"phc_ubuPhiqqjMdedpmbWpG2Ak3axqv5eMVhFDNBaXl9UZK\", - \"event\": \"preinst\", - \"properties\": { - \"distinct_id\": \"$telemetry_id\" - } - }" \ - https://t.firez.one/capture/ > /dev/null - fi - fi - fi -} -if [ ! -e /var/opt/firezone/.disable_telemetry ]; then - capture || true -fi - -kernelCheck -configCheck -echo "You're about to install firezone!" diff --git a/omnibus/package-scripts/firezone/prerm b/omnibus/package-scripts/firezone/prerm deleted file mode 100755 index b961246c1..000000000 --- a/omnibus/package-scripts/firezone/prerm +++ /dev/null @@ -1,40 +0,0 @@ -#!/bin/sh -# -# Perform necessary firezone setup steps -# prior to uninstalling package. -# - -PROGNAME=`basename $0` - -capture () { - if type curl > /dev/null; then - if [ -e /var/opt/firezone/cache/telemetry_id ]; then - telemetry_id=`cat /var/opt/firezone/cache/telemetry_id` - if [ ! -z "$telemetry_id" ]; then - curl -s -XPOST \ - -m 5 \ - -H 'Content-Type: application/json' \ - -d "{ - \"api_key\": \"phc_ubuPhiqqjMdedpmbWpG2Ak3axqv5eMVhFDNBaXl9UZK\", - \"event\": \"prerm\", - \"properties\": { - \"distinct_id\": \"$telemetry_id\" - } - }" \ - https://t.firez.one/capture/ > /dev/null - fi - fi - fi -} - -if [ ! -e /var/opt/firezone/.disable_telemetry ]; then - capture || true -fi - -error_exit() -{ - echo "${PROGNAME}: ${1:-"Unknown Error"}" 1>&2 - exit 1 -} - -exit 0 diff --git a/www/docs/administer/regen-keys.mdx b/www/docs/administer/regen-keys.mdx index 14c1e487b..c9abd1250 100644 --- a/www/docs/administer/regen-keys.mdx +++ b/www/docs/administer/regen-keys.mdx @@ -39,14 +39,6 @@ docker run firezone/firezone bin/gen-env > .env Now, move desired env vars from `.env.bak` back to `.env`, keeping the new secrets intact. - - - -```bash -mv /etc/firezone/secrets.json /etc/firezone/secrets.bak.json -sudo firezone-ctl reconfigure -``` - @@ -71,14 +63,5 @@ sudo mv firezone/private_key firezone/private_key.bak docker-compose start firezone ``` - - - -```bash -sudo firezone-ctl stop phoenix -sudo mv /var/opt/firezone/cache/wg_private_key /var/opt/firezone/cache/wg_private_key.bak -sudo firezone-ctl start phoenix -``` - diff --git a/www/docs/administer/troubleshoot.mdx b/www/docs/administer/troubleshoot.mdx index da944cf2f..01e722646 100644 --- a/www/docs/administer/troubleshoot.mdx +++ b/www/docs/administer/troubleshoot.mdx @@ -16,12 +16,6 @@ Each container stores logs as a JSON file on the host machine. These can be show See [debug logs](../debug-logs) for additional details. - - - -Firezone logs are stored in `/var/log/firezone` and can be viewed with -`sudo firezone-ctl tail`. - @@ -45,19 +39,6 @@ Similarly, to clear SAML configs: psql -d firezone -h 127.0.0.1 -U postgres -c "UPDATE configurations SET saml_identity_providers = '[]'" ``` - - - -```text -/opt/firezone/embedded/bin/psql -d $DATABASE_NAME -h $DATABASE_HOST -U $DATABASE_USER -c "UPDATE configurations SET openid_connect_providers = '[]'" -``` - -Similarly, to clear SAML configs: - -```text -/opt/firezone/embedded/bin/psql -d $DATABASE_NAME -h $DATABASE_HOST -U $DATABASE_USER -c "UPDATE configurations SET saml_identity_providers = '[]'" -``` - @@ -80,31 +61,7 @@ is enabled and configured automatically. In most cases, you'll find clues in one or more of the following locations: - - - -- Your browser's developer tool logs, specifically the `Network` tab. -- `sudo firezone-ctl tail nginx` -- `sudo firezone-ctl tail phoenix` - -If the websocket connection is successful, you should see output in the -`phoenix` service logs similar the following: - -```text -2022-09-23_15:05:47.29158 15:05:47.291 [info] CONNECTED TO Phoenix.LiveView.Socket in 24µs -2022-09-23_15:05:47.29160 Transport: :websocket -2022-09-23_15:05:47.29160 Serializer: Phoenix.Socket.V2.JSONSerializer -2022-09-23_15:05:47.29161 Parameters: %{"_csrf_token" => "XFEFCHQ2fRQABQwtKQdCJDlFAzEcCCJvn7LqDsMXE4eGZtsBzuwVRCJ6", "_mounts" => "0", "_track_static" => %{"0" => "https://demo.firez.one/dist/admin-02fabe0f543c64122dbf5bc5b3451e51.css?vsn=d", "1" => "https://demo.firez.one/dist/admin-04e75c78295062c2c07af61be50248b0.js?vsn=d"}, "vsn" => "2.0.0"} -2022-09-23_15:05:47.33655 15:05:47.336 [info] CONNECTED TO FzHttpWeb.UserSocket in 430µs -2022-09-23_15:05:47.33657 Transport: :websocket -2022-09-23_15:05:47.33658 Serializer: Phoenix.Socket.V2.JSONSerializer -2022-09-23_15:05:47.33658 Parameters: %{"token" => "SFMyNTY.g2gDYQFuBgB6HeJqgwFiAAFRgA.qKoC2bi9DubPkE0tfaRSPERWUFyQQPQV5n4nFKVppxc", "vsn" => "2.0.0"} -2022-09-23_15:05:47.35063 15:05:47.350 [info] JOINED notification:session in 636µs -2022-09-23_15:05:47.35065 Parameters: %{"token" => "SFMyNTY.g2gDYQFuBgB6HeJqgwFiAAFRgA.zSG7pefm-Vgf_zvduxa5E9VK4s8PKqzc0xBDGNx5FQE", "user_agent" => "Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:106.0) Gecko/20100101 Firefox/106.0"} -``` - - - + ## Debugging WireGuard connectivity issues @@ -171,15 +128,6 @@ docker compose exec firezone bin/create-or-reset-admin **Note**: If local authentication is disabled, resetting the admin user's password will not re-enable it. - - - -Run the following command to reset the password on the default admin user. - -```shell -sudo firezone-ctl create-or-reset-admin -``` - diff --git a/www/docs/authenticate/saml/README.mdx b/www/docs/authenticate/saml/README.mdx index 410929122..9c6c09f27 100644 --- a/www/docs/authenticate/saml/README.mdx +++ b/www/docs/authenticate/saml/README.mdx @@ -53,18 +53,6 @@ save these files to `$HOME/.firezone/firezone` on the Docker host and set the `SAML_CERTFILE_PATH=/var/firezone/saml.crt` environment variables for the Firezone container. - - - -Set the following attributes in your `/etc/firezone/firezone.rb` configuration file: - -```ruby -default['firezone']['authentication']['saml']['key'] = '/path/to/your/saml.key' -default['firezone']['authentication']['saml']['cert'] = '/path/to/your/saml.crt' -``` - -and run `firezone-ctl reconfigure` to pick up the changes. - diff --git a/www/docs/deploy/README.mdx b/www/docs/deploy/README.mdx index ab2103053..136409fe8 100644 --- a/www/docs/deploy/README.mdx +++ b/www/docs/deploy/README.mdx @@ -45,23 +45,6 @@ it's available on port 80/tcp and the DNS record for the server is valid. See the [Docker deployment guide](docker) for more info. - - - -For Omnibus-based deployments, ACME is disabled by default to maintain -compatibility with existing installations. - -To enable ACME, ensure the following conditions are met: - -* `80/tcp` is allow inbound -* The bundled Firezone `nginx` service is enabled and functioning -* You have a valid DNS record assigned to this instance's public IP -* The following 3 settings are configured in the [configuration file](../reference/configuration-file): - * `default['firezone']['external_url']`: The FQDN for the server. - * `default['firezone']['ssl']['email_address']`: The email that will be used - for the issued certificates. - * `default['firezone']['ssl']['acme']['enabled']`: Set this to true to enable it. - diff --git a/www/docs/deploy/advanced/external-database.mdx b/www/docs/deploy/advanced/external-database.mdx index d5a4b0279..867fddcb4 100644 --- a/www/docs/deploy/advanced/external-database.mdx +++ b/www/docs/deploy/advanced/external-database.mdx @@ -54,27 +54,5 @@ environment variables for the container. See the Postgres image [documentation](https://hub.docker.com/_/postgres) for more details. ::: - - - -The following configuration options are used to configure the bundled Postgres -for Omnibus-based deployments: - -| Config Key | Description | Default | -| ----------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------- | -| `default['firezone']['database']['user']` | Specifies the username Firezone will use to connect to the DB. | `node['firezone']['postgresql']['username']` | -| `default['firezone']['database']['password']` | If using an external DB, specifies the password Firezone will use to connect to the DB. | `'change_me'` | -| `default['firezone']['database']['name']` | Database that Firezone will use. Will be created if it doesn't exist. | `'firezone'` | -| `default['firezone']['database']['host']` | Database host that Firezone will connect to. | `node['firezone']['postgresql']['listen_address']` | -| `default['firezone']['database']['port']` | Database port that Firezone will connect to. | `node['firezone']['postgresql']['port']` | -| `default['firezone']['database']['pool']` | Database pool size Firezone will use. | `[10, Etc.nprocessors].max` | -| `default['firezone']['database']['ssl']` | Whether to connect to the database over SSL. | `false` | -| `default['firezone']['database']['ssl_opts']` | Hash of options to send to the `:ssl_opts` option when connecting over SSL. See [Ecto.Adapters.Postgres documentation](https://hexdocs.pm/ecto_sql/Ecto.Adapters.Postgres.html#module-connection-options). | `{}` | -| `default['firezone']['database']['parameters']` | Hash of parameters to send to the `:parameters` option when connecting to the database. See [Ecto.Adapters.Postgres documentation](https://hexdocs.pm/ecto_sql/Ecto.Adapters.Postgres.html#module-connection-options). | `{}` | -| `default['firezone']['database']['extensions']` | Database extensions to enable. | `{ 'plpgsql' => true, 'pg_trgm' => true }` | - -For more details, see the [configuration file reference -](/docs/reference/configuration-file/). - diff --git a/www/docs/deploy/configure.mdx b/www/docs/deploy/configure.mdx index 9c90218f7..1788ebd35 100644 --- a/www/docs/deploy/configure.mdx +++ b/www/docs/deploy/configure.mdx @@ -41,22 +41,5 @@ for a complete listing. See [Docker's documentation ](https://docs.docker.com/compose/envvars-precedence/) for more information. - - - -For Omnibus-based deployments, Firezone leverages [Chef Omnibus -](https://github.com/chef/omnibus) to handle release packaging, process -supervision, log management, and more. - -The main configuration file is written in [Ruby](https://ruby-lang.org) and can -be found at `/etc/firezone/firezone.rb` on a default installation. -Changing this file **requires re-running** `sudo firezone-ctl reconfigure` -which triggers Chef to pick up the changes and apply them to the running -system. - -For an exhaustive list of Omnibus configuration variables and their -descriptions, see the [configuration file reference -](../../reference/configuration-file). - diff --git a/www/docs/deploy/omnibus/README.mdx b/www/docs/deploy/omnibus/README.mdx deleted file mode 100644 index 804585564..000000000 --- a/www/docs/deploy/omnibus/README.mdx +++ /dev/null @@ -1,195 +0,0 @@ ---- -title: Omnibus -sidebar_position: 3 -description: - Install Firezone via our Omnibus deployment option to manage - secure access to private networks and resources. ---- - -# Install Firezone with Omnibus - -:::caution -Due to Omnibus being EOL'd by Chef in 2024, Docker is now the preferred method -of deploying Firezone. See the [Docker deployment guide](../docker) to get -started. - -Read below to continue with an Omnibus-based deployment. -::: - -Firezone can be deployed on a server running a supported [Linux distribution -](supported-platforms) in a few minutes with our Debian or Red Hat package. -This guide will walk you through the steps to get started. - -## Step 1: Prerequisites - -* Ensure you're on a [supported Linux distribution](supported-platforms). - A kernel upgrade may be required to ensure WireGuard® is available. -* Ensure port forwarding is enabled on your firewall. - The default Firezone configuration requires the following ports to be open: - * `80/tcp` (optional): For automatically issuing SSL certificates. - * `443/tcp`: To access the web UI. - * `51820/udp`: VPN traffic listen port. - -:::caution -Before deploying Firezone in **production**, you'll need a valid DNS record -pointing to this instance. See [Prepare to Deploy](../#prepare-to-deploy) -if you haven't done this already. -::: - -:::note -Firezone modifies the kernel netfilter and routing tables. -Other programs that modify the Linux routing table or firewall may interfere -with Firezone’s operation. For help troubleshooting connectivity issues, see the -[troubleshooting guide](../../administer/troubleshoot). -::: - -## Step 2: Install server - -After prerequisites are satisfied, you're ready to install the Firezone Server. - -### Option 1: Automatic install - -The easiest way to get started using Firezone is via the automatic installation -script below. - -```bash -sudo -E bash -c "$(curl -fsSL https://github.com/firezone/firezone/raw/master/scripts/omnibus_install.sh)" -``` - -This will ask you a few questions regarding your install, install the latest -release for your platform, create an administrator user, then print to the -console instructions for logging in to the web UI. - -![install complete](https://user-images.githubusercontent.com/52545545/171948328-4771552f-e5dd-4c30-8c0b-baac80b6e7b1.png) - -By default, the web UI can be reached at the IP or domain name of your server. -You can regenerate the admin credentials using the -`firezone-ctl create-or-reset-admin` command. - -### Option 2: Install from our Debian or RedHat repositories - -If the automatic install script fails, try these steps to install Firezone from our -[Cloudsmith repository](https://cloudsmith.io/~firezone/repos/firezone). - -1. [Install WireGuard](https://www.wireguard.com/install/) for your distro. - If using Linux kernel 5.6 or higher, skip this step. - -1. Install our package repository for your distro's package format: - - deb packages: - - ```bash - curl -1sLf \ - 'https://dl.cloudsmith.io/public/firezone/firezone/setup.deb.sh' \ - | sudo -E bash - ``` - - See the [Debian setup docs](https://cloudsmith.io/~firezone/repos/firezone/setup/#formats-deb) - for more options if the script fails to setup the repo. - - - rpm packages: - - ```bash - curl -1sLf \ - 'https://dl.cloudsmith.io/public/firezone/firezone/setup.rpm.sh' \ - | sudo -E bash - ``` - - See the [RedHat setup docs](https://cloudsmith.io/~firezone/repos/firezone/setup/#formats-rpm) - for more options if the script fails to setup the repo. - -1. Install Firezone with your distro's package manager: - - ```bash - # Using apt - sudo apt install firezone - - # Using dnf - sudo dnf install firezone - - # Using yum - sudo yum install firezone - - # Using zypper - sudo zypper install firezone - ``` - -1. Follow the [bootstrap instructions](#bootstrap-firezone) to setup Firezone. - -### Option 3: Manual install - -If all else fails, try these steps to install Firezone manually. - -1. [Install WireGuard](https://www.wireguard.com/install/) for your distro. - If using Linux kernel 5.6 or higher, skip this step. -1. Download the relevant package for your distribution from the [releases page](https://github.com/firezone/firezone/releases). -1. Install with `sudo rpm -i firezone*.rpm` or `sudo dpkg -i firezone*.deb` - depending on your distro. -1. Follow the [bootstrap instructions](#bootstrap-firezone) to setup Firezone. - -### Bootstrap Firezone - -1. Bootstrap the application with `sudo firezone-ctl reconfigure`. This will - initialize config files, set up needed services and generate the default - configuration. -1. Edit the default configuration located at `/etc/firezone/firezone.rb`. - We've chosen sensible defaults that should be a good starting point for most - installations. For production installations, you'll want to specify a valid - external URL and enable ACME for certificate issuance and renewal: - - ```ruby - # Auto-generated based on the server's hostname. - # Set this to the URL used to access the Firezone Web UI. - default['firezone']['external_url'] = 'https://firezone.example.com' - - # Set the email that will be used for the issued certificates and certifications. - default['firezone']['ssl']['email_address'] = 'your@email.com' - - # Enable ACME renewal - default['firezone']['ssl']['acme']['enabled'] = true - ``` - - See the complete [configuration file reference for more details - ](../../reference/configuration-file). - -1. Reconfigure the application to pick up the new changes: - `sudo firezone-ctl reconfigure`. -1. Finally, create an admin user with `sudo firezone-ctl create-or-reset-admin`. - The login credentials will be printed to the console output. -1. Now you should be able to sign in to the web UI at the URL you specified in - step 5 above, e.g. `https://firezone.example.com` - -Find solutions to common issues during deployment in [Troubleshoot -](../../administer/troubleshoot). - -## Step 3: Install client apps - -Once successfully deployed, users and devices can be added to -connect to the VPN server: - -* [Add Users](../../user-guides/add-users): -Add users to grant them access to your network. -* [Client Instructions](../../user-guides/client-instructions): -Instructions to establish a VPN session. - -import SupportOptions from '@site/src/partials/_support_options.mdx'; - - -## Post setup - -Congrats! You have completed the setup, but there's a lot more you can do with -Firezone: - -* [Integrate your identity provider](../../authenticate/) - for authenticating clients -* Using Firezone to - [establish a static IP](../../user-guides/use-cases/nat-gateway) -* Create tunnels between multiple peers with - [reverse tunnels](../../user-guides/use-cases/reverse-tunnel) -* Only route certain traffic through Firezone with - [split tunneling](../../user-guides/use-cases/split-tunnel) - -Support us by: - -* Starring our repo on [Github](https://github.com/firezone/firezone) -* Following us on Twitter at [@firezonehq](https://twitter.com/firezonehq) -* Following us on LinkedIn at [@firezonehq](https://www.linkedin.com/company/firezonehq) diff --git a/www/docs/deploy/omnibus/supported-platforms.mdx b/www/docs/deploy/omnibus/supported-platforms.mdx deleted file mode 100644 index 9998ea840..000000000 --- a/www/docs/deploy/omnibus/supported-platforms.mdx +++ /dev/null @@ -1,121 +0,0 @@ ---- -title: Supported Platforms -sidebar_position: 1 ---- - -Omnibus Firezone currently supports the following platforms: - -| OS | Architectures | Status | Notes | -| --- | --- | --- | --- | -| AmazonLinux 2 | `amd64` `arm64` | **Fully-supported** | See [AmazonLinux 2 Notes](#amazonlinux-2-notes) | -| CentOS 7 | `amd64` | **Fully-supported** | See [CentOS 7 Notes](#centos-7-notes) | -| CentOS 8 | `amd64` `arm64` | **Fully-supported** | See [CentOS 8 Notes](#centos-8-notes) | -| CentOS Stream 9 | `amd64` `arm64` | **Fully-supported** | Works as-is | -| Red Hat Enterprise Linux 7 | `amd64` | **Fully-supported** | See [RHEL 7 Notes](#rhel-7-notes) | -| Red Hat Enterprise Linux 8 | `amd64` `arm64` | **Fully-supported** | See [RHEL 8 Notes](#rhel-8-notes) | -| Red Hat Enterprise Linux 9 | `amd64` `arm64` | **Fully-supported** | See [RHEL 9 Notes](#rhel-9-notes) | -| Debian 10 | `amd64` `arm64` | **Fully-supported** | See [Debian 10 Notes](#debian-10-notes)| -| Debian 11 | `amd64` `arm64` | **Fully-supported** | Works as-is | -| Fedora 33 | `amd64` `arm64` | **Fully-supported** | See [Fedora Notes](#fedora-notes) | -| Fedora 34 | `amd64` `arm64` | **Fully-supported** | See [Fedora Notes](#fedora-notes) | -| Fedora 35 | `amd64` `arm64` | **Fully-supported** | See [Fedora Notes](#fedora-notes) | -| Ubuntu 18.04 | `amd64` `arm64` | **Fully-supported** | See [Ubuntu 18.04 Notes](#ubuntu-1804-notes) | -| Ubuntu 20.04 | `amd64` `arm64` | **Fully-supported** | Works as-is | -| Ubuntu 22.04 | `amd64` `arm64` | **Fully-supported** | Works as-is | -| openSUSE Leap 15.3 | `amd64` | **Fully-supported** | See [openSUSE Notes](#opensuse-notes) | - -If your distro isn't listed here please try using a package for the closest -distro first. For example, since Raspberry Pi OS is based on Debian, try using -the Debian Firezone package. - -If that doesn't work, please -[open an issue](https://github.com/firezone/firezone/issues/new/choose) -and let us know. New distros are being supported on a regular basis and there's -a good chance yours will be added soon. - -Note that we only support RPM and DEB based packaging systems. Others, like Arch -Linux are currently being investigated [ -in this issue](https://github.com/firezone/firezone/issues/378). - -## AmazonLinux 2 notes - -Kernel upgrade required: - -```shell -sudo amazon-linux-extras install -y kernel-5.10 -``` - -## CentOS 7 notes - -Kernel upgrade to 5.6+ required. To upgrade to the latest mainline kernel and -select it as the default boot kernel: - -```shell -sudo rpm --import https://www.elrepo.org/RPM-GPG-KEY-elrepo.org -sudo yum install -y https://www.elrepo.org/elrepo-release-7.el7.elrepo.noarch.rpm -sudo yum install -y elrepo-release -sudo yum --enablerepo=elrepo-kernel install -y kernel-ml -sudo grub2-set-default 0 -sudo grub2-mkconfig -o /boot/grub2/grub.cfg -sudo reboot -``` - -## CentOS 8 notes - -The WireGuard kernel module needs to be installed: - -```shell -yum install elrepo-release epel-release -yum install kmod-wireguard -``` - -## RHEL 7 notes - -Red Hat Enterprise Linux is binary compatible with CentOS, so the Firezone -package for CentOS 7 should work just fine for RHEL 7. You'll still need to -upgrade your kernel to 5.6+ however. To do so, follow the steps for -[CentOS 7 Notes](#centos-7-notes) above. - -## RHEL 8 notes - -Red Hat Enterprise Linux is binary compatible with CentOS, so the Firezone -package for CentOS 8 should work just fine for RHEL 8. You'll still need to -install the WireGuard kernel module, however. See [CentOS 8 Notes -](#centos-8-notes) above. - -## RHEL 9 notes - -Use the package for CentOS 9. - -## Fedora notes - -On fresh Fedora installations you'll probably need to install a cron -implementation to support the logrotate functionality, otherwise -you may receive errors about a missing `/etc/cron.hourly` directory. - -```shell -yum install cronie-anacron -``` - -## Ubuntu 18.04 notes - -Kernel upgrade to 5.4+ required: - -```shell -sudo apt install linux-image-generic-hwe-18.04 -``` - -## Debian 10 notes - -Kernel upgrade to 5.6+ required. See [this guide -](https://jensd.be/968/linux/install-a-newer-kernel-in-debian-10-buster-stable) -for an example. - -## openSUSE notes - -Firezone requires the `setcap` utility, but some recent openSUSE releases may -not have it installed by default. To fix, ensure `libcap-progs` is installed: - -```shell -sudo zypper install libcap-progs -``` diff --git a/www/docs/reference/telemetry.mdx b/www/docs/reference/telemetry.mdx index 52d14ef06..620e450ab 100644 --- a/www/docs/reference/telemetry.mdx +++ b/www/docs/reference/telemetry.mdx @@ -86,15 +86,5 @@ Telemetry is enabled by default. To completely disable product telemetry: Set the `TELEMETRY_ENABLED` environment variable to `false` and restart the `firezone` container. - - - -Set the following configuration option to `false` in `/etc/firezone/firezone.rb` -and run `sudo firezone-ctl reconfigure` to pick up the changes. - -```ruby -default['firezone']['telemetry']['enabled'] = false -``` -