1
0
mirror of https://git.FreeBSD.org/src.git synced 2024-12-23 11:18:54 +00:00
freebsd/lib/libmp/mp.h
Ed Schouten b3aaa0cc21 Rename all symbols in libmp(3) to mp_*, just like Solaris.
The function pow() in libmp(3) clashes with pow(3) in libm. We could
rename this single function, but we can just take the same approach as
the Solaris folks did, which is to prefix all function names with mp_.

libmp(3) isn't really popular nowadays. I suspect not a single
application in ports depends on it. There's still a chance, so I've
increased the SHLIB_MAJOR and __FreeBSD_version.

Reviewed by:	deischen, rdivacky
2009-02-26 21:43:15 +00:00

33 lines
857 B
C

/* $FreeBSD$ */
#ifndef _MP_H_
#define _MP_H_
#ifndef HEADER_BN_H_
#include <openssl/bn.h>
#endif
typedef struct _mint {
BIGNUM *bn;
} MINT;
void mp_gcd(const MINT *, const MINT *, MINT *);
MINT *mp_itom(short);
void mp_madd(const MINT *, const MINT *, MINT *);
int mp_mcmp(const MINT *, const MINT *);
void mp_mdiv(const MINT *, const MINT *, MINT *, MINT *);
void mp_mfree(MINT *);
void mp_min(MINT *);
void mp_mout(const MINT *);
void mp_move(const MINT *, MINT *);
void mp_msqrt(const MINT *, MINT *, MINT *);
void mp_msub(const MINT *, const MINT *, MINT *);
char *mp_mtox(const MINT *);
void mp_mult(const MINT *, const MINT *, MINT *);
void mp_pow(const MINT *, const MINT *, const MINT *, MINT *);
void mp_rpow(const MINT *, short, MINT *);
void mp_sdiv(const MINT *, short, MINT *, short *);
MINT *mp_xtom(const char *);
#endif /* !_MP_H_ */