diff options
author | Werner Koch <wk@gnupg.org> | 2007-05-31 09:48:05 +0000 |
---|---|---|
committer | Werner Koch <wk@gnupg.org> | 2007-05-31 09:48:05 +0000 |
commit | bce92d459eda6e33512a63bdd97e84f0499e4207 (patch) | |
tree | c16c37ef9a8e58ec218c818dc69696fd76f6ece6 /cipher | |
parent | b9da12b6346a6c68eb6f514195e6bb5d9d33d454 (diff) | |
download | libgcrypt-bce92d459eda6e33512a63bdd97e84f0499e4207.tar.gz |
Camellia is now LGPLed
Diffstat (limited to 'cipher')
-rw-r--r-- | cipher/ChangeLog | 5 | ||||
-rw-r--r-- | cipher/camellia.c | 20 | ||||
-rw-r--r-- | cipher/camellia.h | 55 |
3 files changed, 47 insertions, 33 deletions
diff --git a/cipher/ChangeLog b/cipher/ChangeLog index 8a5c5e98..da784fd6 100644 --- a/cipher/ChangeLog +++ b/cipher/ChangeLog @@ -1,3 +1,8 @@ +2007-05-30 Werner Koch <wk@g10code.com> + + * camellia.h, camellia.c: Replace by new LGPL version and adjusted + camellia.h. + 2007-05-09 Marcus Brinkmann <marcus@g10code.de> * ac.c (_gcry_ac_io_init_va, _gcry_ac_io_write, _gcry_ac_io_read): diff --git a/cipher/camellia.c b/cipher/camellia.c index c32c406b..79cd49b7 100644 --- a/cipher/camellia.c +++ b/cipher/camellia.c @@ -3,19 +3,19 @@ * Copyright (C) 2006,2007 * NTT (Nippon Telegraph and Telephone Corporation). * - * This program is free software; you can redistribute it and/or - * modify it under the terms of the GNU General Public License - * as published by the Free Software Foundation; either version 2 - * of the License, or (at your option) any later version. + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2.1 of the License, or (at your option) any later version. * - * This program is distributed in the hope that it will be useful, + * This library is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA */ /* diff --git a/cipher/camellia.h b/cipher/camellia.h index 26a88d6c..3a92dc4d 100644 --- a/cipher/camellia.h +++ b/cipher/camellia.h @@ -3,37 +3,46 @@ * Copyright (C) 2006,2007 * NTT (Nippon Telegraph and Telephone Corporation). * - * This program is free software; you can redistribute it and/or - * modify it under the terms of the GNU General Public License - * as published by the Free Software Foundation; either version 2 - * of the License, or (at your option) any later version. + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2.1 of the License, or (at your option) any later version. * - * This program is distributed in the hope that it will be useful, + * This library is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA */ #ifndef HEADER_CAMELLIA_H #define HEADER_CAMELLIA_H -/* Need to redefine the external symbols to keep the libgcrypt name - space clean. */ -#define Camellia_Ekeygen _gcry_Camellia_Ekeygen -#define Camellia_EncryptBlock _gcry_Camellia_EncryptBlock -#define Camellia_DecryptBlock _gcry_Camellia_DecryptBlock -#define camellia_decrypt128 _gcry_camellia_decrypt128 -#define camellia_decrypt256 _gcry_camellia_decrypt256 -#define camellia_encrypt128 _gcry_camellia_encrypt128 -#define camellia_encrypt256 _gcry_camellia_encrypt256 -#define camellia_setup128 _gcry_camellia_setup128 -#define camellia_setup192 _gcry_camellia_setup192 -#define camellia_setup256 _gcry_camellia_setup256 - +/* To use Camellia with libraries it is often useful to keep the name + * space of the library clean. The following macro is thus useful: + * + * #define CAMELLIA_EXT_SYM_PREFIX foo_ + * + * This prefixes all external symbols with "foo_". + */ +#ifdef CAMELLIA_EXT_SYM_PREFIX +#define CAMELLIA_PREFIX1(x,y) x ## y +#define CAMELLIA_PREFIX2(x,y) CAMELLIA_PREFIX1(x,y) +#define CAMELLIA_PREFIX(x) CAMELLIA_PREFIX2(CAMELLIA_EXT_SYM_PREFIX,x) +#define Camellia_Ekeygen CAMELLIA_PREFIX(Camellia_Ekeygen) +#define Camellia_EncryptBlock CAMELLIA_PREFIX(Camellia_EncryptBlock) +#define Camellia_DecryptBlock CAMELLIA_PREFIX(Camellia_DecryptBlock) +#define camellia_decrypt128 CAMELLIA_PREFIX(camellia_decrypt128) +#define camellia_decrypt256 CAMELLIA_PREFIX(camellia_decrypt256) +#define camellia_encrypt128 CAMELLIA_PREFIX(camellia_encrypt128) +#define camellia_encrypt256 CAMELLIA_PREFIX(camellia_encrypt256) +#define camellia_setup128 CAMELLIA_PREFIX(camellia_setup128) +#define camellia_setup192 CAMELLIA_PREFIX(camellia_setup192) +#define camellia_setup256 CAMELLIA_PREFIX(camellia_setup256) +#endif /*CAMELLIA_EXT_SYM_PREFIX*/ #ifdef __cplusplus extern "C" { |