{
    "mode": "man",
    "parameter": "krb5-config",
    "section": "1",
    "url": "https://www.chedong.com/phpMan.php/man/krb5-config/1/json",
    "generated": "2026-06-13T21:24:04Z",
    "synopsis": "krb5-config [--help | --all | --version | --vendor | --prefix | --exec-prefix | --defccname |\n--defktname | --defcktname | --cflags | --libs [libraries]]",
    "sections": {
        "NAME": {
            "content": "krb5-config - tool for linking against MIT Kerberos libraries\n",
            "subsections": []
        },
        "SYNOPSIS": {
            "content": "krb5-config [--help | --all | --version | --vendor | --prefix | --exec-prefix | --defccname |\n--defktname | --defcktname | --cflags | --libs [libraries]]\n",
            "subsections": []
        },
        "DESCRIPTION": {
            "content": "krb5-config tells the application programmer what flags to use to compile and  link  programs\nagainst the installed Kerberos libraries.\n",
            "subsections": []
        },
        "OPTIONS": {
            "content": "--help prints a usage message.  This is the default behavior when no options are specified.\n\n--all  prints the version, vendor, prefix, and exec-prefix.\n",
            "subsections": [
                {
                    "name": "--version",
                    "content": "prints the version number of the Kerberos installation.\n",
                    "long": "--version"
                },
                {
                    "name": "--vendor",
                    "content": "prints the name of the vendor of the Kerberos installation.\n",
                    "long": "--vendor"
                },
                {
                    "name": "--prefix",
                    "content": "prints the prefix for which the Kerberos installation was built.\n",
                    "long": "--prefix"
                },
                {
                    "name": "--exec-prefix",
                    "content": "prints the prefix for executables for which the Kerberos installation was built.\n",
                    "long": "--exec-prefix"
                },
                {
                    "name": "--defccname",
                    "content": "prints the built-in default credentials cache location.\n",
                    "long": "--defccname"
                },
                {
                    "name": "--defktname",
                    "content": "prints the built-in default keytab location.\n",
                    "long": "--defktname"
                },
                {
                    "name": "--defcktname",
                    "content": "prints the built-in default client (initiator) keytab location.\n",
                    "long": "--defcktname"
                },
                {
                    "name": "--cflags",
                    "content": "prints the compilation flags used to build the Kerberos installation.\n\n--libs [library]\nprints  the  compiler  options needed to link against library.  Allowed values for li‐\nbrary are:\n\n┌────────────┬───────────────────────────────────┐\n│krb5        │ Kerberos 5 applications (default) │\n├────────────┼───────────────────────────────────┤\n│gssapi      │ GSSAPI applications with Kerberos │\n│            │ 5 bindings                        │\n├────────────┼───────────────────────────────────┤\n│kadm-client │ Kadmin client                     │\n├────────────┼───────────────────────────────────┤\n│kadm-server │ Kadmin server                     │\n├────────────┼───────────────────────────────────┤\n│kdb         │ Applications that access the Ker‐ │\n│            │ beros database                    │\n└────────────┴───────────────────────────────────┘\n",
                    "long": "--cflags"
                }
            ]
        },
        "EXAMPLES": {
            "content": "krb5-config is particularly useful for compiling against a Kerberos installation that was in‐\nstalled  in  a non-standard location.  For example, a Kerberos installation that is installed\nin /opt/krb5/ but uses libraries in /usr/local/lib/ for text localization would  produce  the\nfollowing output:\n\nshell% krb5-config --libs krb5\n-L/opt/krb5/lib -Wl,-rpath -Wl,/opt/krb5/lib -L/usr/local/lib -lkrb5 -lk5crypto -lcomerr\n",
            "subsections": []
        },
        "SEE ALSO": {
            "content": "kerberos(7), cc(1)\n",
            "subsections": []
        },
        "AUTHOR": {
            "content": "MIT\n",
            "subsections": []
        },
        "COPYRIGHT": {
            "content": "1985-2021, MIT\n\n\n\n\n1.19.2                                                                                KRB5-CONFIG(1)",
            "subsections": []
        }
    },
    "summary": "krb5-config - tool for linking against MIT Kerberos libraries",
    "flags": [
        {
            "flag": "",
            "long": "--version",
            "arg": null,
            "description": "prints the version number of the Kerberos installation."
        },
        {
            "flag": "",
            "long": "--vendor",
            "arg": null,
            "description": "prints the name of the vendor of the Kerberos installation."
        },
        {
            "flag": "",
            "long": "--prefix",
            "arg": null,
            "description": "prints the prefix for which the Kerberos installation was built."
        },
        {
            "flag": "",
            "long": "--exec-prefix",
            "arg": null,
            "description": "prints the prefix for executables for which the Kerberos installation was built."
        },
        {
            "flag": "",
            "long": "--defccname",
            "arg": null,
            "description": "prints the built-in default credentials cache location."
        },
        {
            "flag": "",
            "long": "--defktname",
            "arg": null,
            "description": "prints the built-in default keytab location."
        },
        {
            "flag": "",
            "long": "--defcktname",
            "arg": null,
            "description": "prints the built-in default client (initiator) keytab location."
        },
        {
            "flag": "",
            "long": "--cflags",
            "arg": null,
            "description": "prints the compilation flags used to build the Kerberos installation. --libs [library] prints the compiler options needed to link against library. Allowed values for li‐ brary are: ┌────────────┬───────────────────────────────────┐ │krb5 │ Kerberos 5 applications (default) │ ├────────────┼───────────────────────────────────┤ │gssapi │ GSSAPI applications with Kerberos │ │ │ 5 bindings │ ├────────────┼───────────────────────────────────┤ │kadm-client │ Kadmin client │ ├────────────┼───────────────────────────────────┤ │kadm-server │ Kadmin server │ ├────────────┼───────────────────────────────────┤ │kdb │ Applications that access the Ker‐ │ │ │ beros database │ └────────────┴───────────────────────────────────┘"
        }
    ],
    "examples": [
        "krb5-config is particularly useful for compiling against a Kerberos installation that was in‐",
        "stalled  in  a non-standard location.  For example, a Kerberos installation that is installed",
        "in /opt/krb5/ but uses libraries in /usr/local/lib/ for text localization would  produce  the",
        "following output:",
        "shell% krb5-config --libs krb5",
        "-L/opt/krb5/lib -Wl,-rpath -Wl,/opt/krb5/lib -L/usr/local/lib -lkrb5 -lk5crypto -lcomerr"
    ],
    "see_also": [
        {
            "name": "kerberos",
            "section": "7",
            "url": "https://www.chedong.com/phpMan.php/man/kerberos/7/json"
        },
        {
            "name": "cc",
            "section": "1",
            "url": "https://www.chedong.com/phpMan.php/man/cc/1/json"
        }
    ]
}