Same as other patches in this series, use C macros defined at build time to resolve directories.
Signed-off-by: Klaus Heinrich Kiwi <[email protected]> --- configure.in | 1 - usr/lib/pkcs11/tpm_stdll/tok_struct.h | 69 ++++++++++++++++++++++++++++++ usr/lib/pkcs11/tpm_stdll/tok_struct.h.in | 59 ------------------------- 3 files changed, 69 insertions(+), 60 deletions(-) create mode 100644 usr/lib/pkcs11/tpm_stdll/tok_struct.h delete mode 100644 usr/lib/pkcs11/tpm_stdll/tok_struct.h.in diff --git a/configure.in b/configure.in index a9a4574..0f1baa0 100644 --- a/configure.in +++ b/configure.in @@ -281,7 +281,6 @@ AC_OUTPUT([Makefile usr/Makefile \ usr/lib/pkcs11/cr_stdll/Makefile \ usr/lib/pkcs11/aep_stdll/Makefile \ usr/lib/pkcs11/tpm_stdll/Makefile \ - usr/lib/pkcs11/tpm_stdll/tok_struct.h \ usr/lib/pkcs11/cca_stdll/Makefile \ usr/lib/pkcs11/methods/4758_status/Makefile \ misc/Makefile \ diff --git a/usr/lib/pkcs11/tpm_stdll/tok_struct.h b/usr/lib/pkcs11/tpm_stdll/tok_struct.h new file mode 100644 index 0000000..cb760ac --- /dev/null +++ b/usr/lib/pkcs11/tpm_stdll/tok_struct.h @@ -0,0 +1,69 @@ +/* + * The Initial Developer of the Original Code is International + * Business Machines Corporation. Portions created by IBM + * Corporation are Copyright (C) 2005 International Business + * Machines Corporation. All Rights Reserved. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the Common Public License as published by + * IBM Corporation; either version 1 of the License, or (at your option) + * any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * Common Public License for more details. + * + * You should have received a copy of the Common Public License + * along with this program; if not, a copy can be viewed at + * http://www.opensource.org/licenses/cpl1.0.php. + */ + +#include "tpm_specific.h" + +#ifndef TPM_CONFIG_PATH + +#ifndef CONFIG_PATH +#warning CONFIG_PATH not set, using default (/usr/local/var/lib/opencryptoki) +#define CONFIG_PATH "/usr/local/var/lib/opencryptoki" +#endif // #ifndef CONFIG_PATH + +#define TPM_CONFIG_PATH CONFIG_PATH "/tpm" +#endif // #ifndef TPM_CONFIG_PATH + +struct token_specific_struct token_specific = { + TPM_CONFIG_PATH, + "tpm", + "TPM_STDLL_Debug", + &token_specific_init, + &tok_slot2local, + &token_rng, + &token_specific_session, + &token_specific_final, + &token_specific_des_key_gen, + &token_specific_des_ecb, + &token_specific_des_cbc, + &token_specific_tdes_ecb, + &token_specific_tdes_cbc, + &token_specific_rsa_decrypt, + &token_specific_rsa_encrypt, + &token_specific_rsa_sign, + &token_specific_rsa_verify, + &token_specific_rsa_generate_keypair, +#ifndef NODH + &token_specific_dh_pkcs_derive, + &token_specific_dh_pkcs_key_pair_gen, +#endif + // SHA-1 - use the internal implementation + NULL, + NULL, + NULL, + &token_specific_aes_key_gen, + &token_specific_aes_ecb, + &token_specific_aes_cbc, + &token_specific_login, + &token_specific_logout, + &token_specific_init_pin, + &token_specific_set_pin, + &token_specific_verify_so_pin +}; diff --git a/usr/lib/pkcs11/tpm_stdll/tok_struct.h.in b/usr/lib/pkcs11/tpm_stdll/tok_struct.h.in deleted file mode 100644 index 8d372f1..0000000 --- a/usr/lib/pkcs11/tpm_stdll/tok_struct.h.in +++ /dev/null @@ -1,59 +0,0 @@ -/* - * The Initial Developer of the Original Code is International - * Business Machines Corporation. Portions created by IBM - * Corporation are Copyright (C) 2005 International Business - * Machines Corporation. All Rights Reserved. - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the Common Public License as published by - * IBM Corporation; either version 1 of the License, or (at your option) - * any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * Common Public License for more details. - * - * You should have received a copy of the Common Public License - * along with this program; if not, a copy can be viewed at - * http://www.opensource.org/licenses/cpl1.0.php. - */ - -#include "tpm_specific.h" - -struct token_specific_struct token_specific = { - "@DB_PATH@/tpm", - "tpm", - "TPM_STDLL_Debug", - &token_specific_init, - &tok_slot2local, - &token_rng, - &token_specific_session, - &token_specific_final, - &token_specific_des_key_gen, - &token_specific_des_ecb, - &token_specific_des_cbc, - &token_specific_tdes_ecb, - &token_specific_tdes_cbc, - &token_specific_rsa_decrypt, - &token_specific_rsa_encrypt, - &token_specific_rsa_sign, - &token_specific_rsa_verify, - &token_specific_rsa_generate_keypair, -#ifndef NODH - &token_specific_dh_pkcs_derive, - &token_specific_dh_pkcs_key_pair_gen, -#endif - // SHA-1 - use the internal implementation - NULL, - NULL, - NULL, - &token_specific_aes_key_gen, - &token_specific_aes_ecb, - &token_specific_aes_cbc, - &token_specific_login, - &token_specific_logout, - &token_specific_init_pin, - &token_specific_set_pin, - &token_specific_verify_so_pin -}; -- 1.6.2.5 ------------------------------------------------------------------------------ Come build with us! The BlackBerry® Developer Conference in SF, CA is the only developer event you need to attend this year. Jumpstart your developing skills, take BlackBerry mobile applications to market and stay ahead of the curve. Join us from November 9-12, 2009. Register now! http://p.sf.net/sfu/devconf _______________________________________________ Opencryptoki-tech mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/opencryptoki-tech
