Put the dependencies back.
[openssl.git] / perl / OpenSSL.xs
1 /*
2 **  OpenSSL.xs
3 */
4
5 #include "openssl.h"
6
7 SV *new_ref(type,obj,mort)
8 char *type;
9 char *obj;
10         {
11         SV *ret;
12
13         if (mort)
14                 ret=sv_newmortal();
15         else
16                 ret=newSViv(0);
17 printf(">new_ref %d\n",type);
18         sv_setref_pv(ret,type,(void *)obj);
19         return(ret);
20         }
21
22 int ex_new(obj,data,ad,idx,argl,argp)
23 char *obj;
24 SV *data;
25 CRYPTO_EX_DATA *ad;
26 int idx;
27 long argl;
28 char *argp;
29         {
30         SV *sv;
31
32 fprintf(stderr,"ex_new %08X %s\n",obj,argp);
33         sv=sv_newmortal();
34         sv_setref_pv(sv,argp,(void *)obj);
35 printf("%d>new_ref '%s'\n",sv,argp);
36         CRYPTO_set_ex_data(ad,idx,(char *)sv);
37         return(1);
38         }
39
40 void ex_cleanup(obj,data,ad,idx,argl,argp)
41 char *obj;
42 SV *data;
43 CRYPTO_EX_DATA *ad;
44 int idx;
45 long argl;
46 char *argp;
47         {
48         pr_name("ex_cleanup");
49 fprintf(stderr,"ex_cleanup %08X %s\n",obj,argp);
50         if (data != NULL)
51                 SvREFCNT_dec((SV *)data);
52         }
53
54 MODULE =  OpenSSL        PACKAGE = OpenSSL
55
56 BOOT:
57         boot_bio();
58         boot_cipher();
59         boot_digest();
60         boot_err();
61         boot_ssl();
62         boot_OpenSSL__BN();
63         boot_OpenSSL__BIO();
64         boot_OpenSSL__Cipher();
65         boot_OpenSSL__MD();
66         boot_OpenSSL__ERR();
67         boot_OpenSSL__SSL();
68         boot_OpenSSL__X509();
69