View | Details | Raw Unified | Return to bug 232953 | Differences between
and this patch

Collapse All | Expand All

(-)mail/opendkim/Makefile (-7 / +1 lines)
Lines 154-165 USES+= bdb Link Here
154
LDFLAGS+=		-lpthread
154
LDFLAGS+=		-lpthread
155
.endif
155
.endif
156
156
157
.include <bsd.port.pre.mk>
158
159
.if ${PORT_OPTIONS:MLUA} && ${LUA_VER_STR} >= 53
160
BROKEN=		Does not build with Lua 5.3: miltertest.c:4171:54: error: too few arguments to function call, expected 5, have 4
161
.endif
162
163
pre-configure:
157
pre-configure:
164
	${REINPLACE_CMD} -e '/PKG_CHECK_MODULES/s/lua5\.[0-9]/lua-${LUA_VER}/' \
158
	${REINPLACE_CMD} -e '/PKG_CHECK_MODULES/s/lua5\.[0-9]/lua-${LUA_VER}/' \
165
	    -e '/PKG_CONFIG/s/cyrussasl/libsasl2/'			 \
159
	    -e '/PKG_CONFIG/s/cyrussasl/libsasl2/'			 \
Lines 175-178 post-install: Link Here
175
	${INSTALL_DATA} ${WRKSRC}/opendkim/opendkim.conf.sample \
169
	${INSTALL_DATA} ${WRKSRC}/opendkim/opendkim.conf.sample \
176
	    ${STAGEDIR}${PREFIX}/etc/mail/
170
	    ${STAGEDIR}${PREFIX}/etc/mail/
177
171
178
.include <bsd.port.post.mk>
172
.include <bsd.port.mk>
(-)mail/opendkim/distinfo (+1 lines)
Lines 1-2 Link Here
1
TIMESTAMP = 1544327198
1
SHA256 (opendkim-2.10.3.tar.gz) = 43a0ba57bf942095fe159d0748d8933c6b1dd1117caf0273fa9a0003215e681b
2
SHA256 (opendkim-2.10.3.tar.gz) = 43a0ba57bf942095fe159d0748d8933c6b1dd1117caf0273fa9a0003215e681b
2
SIZE (opendkim-2.10.3.tar.gz) = 1210224
3
SIZE (opendkim-2.10.3.tar.gz) = 1210224
(-)mail/opendkim/files/patch-miltertest_miltertest.c (+20 lines)
Added Link Here
1
--- miltertest/miltertest.c.orig	2014-03-20 04:36:13 UTC
2
+++ miltertest/miltertest.c
3
@@ -4009,7 +4009,7 @@ main(int argc, char **argv)
4
 	}
5
 
6
 	/* register functions */
7
-#if LUA_VERSION_NUM == 502
8
+#if (LUA_VERSION_NUM == 502 || LUA_VERSION_NUM == 503)
9
         luaL_newlib(l, mt_library);
10
 	lua_setglobal(l, "mt");
11
 #else /* LUA_VERSION_NUM == 502 */
12
@@ -4163,7 +4163,7 @@ main(int argc, char **argv)
13
 	lua_setglobal(l, "SMFIF_SETSYMLIST");
14
 #endif /* SMFIF_SETSYMLIST */
15
 
16
-#if LUA_VERSION_NUM == 502
17
+#if (LUA_VERSION_NUM == 502 || LUA_VERSION_NUM == 503)
18
 	switch (lua_load(l, mt_lua_reader, (void *) &io,
19
 	                 script == NULL ? "(stdin)" : script, NULL))
20
 #else /* LUA_VERSION_NUM == 502 */
(-)mail/opendkim/files/patch-opendkim_opendkim-lua.c (+152 lines)
Added Link Here
1
--- opendkim/opendkim-lua.c.orig	2015-02-04 00:31:11 UTC
2
+++ opendkim/opendkim-lua.c
3
@@ -282,7 +282,7 @@ dkimf_lua_alloc(void *ud, void *ptr, size_t osize, siz
4
 		free(ptr);
5
 		return NULL;
6
 	}
7
-# if LUA_VERSION_NUM == 502
8
+# if (LUA_VERSION_NUM == 502 || LUA_VERSION_NUM == 503)
9
 	else if (nsize != 0 && ptr == NULL)
10
 # else /* LUA_VERSION_NUM == 502 */
11
 	else if (nsize != 0 && osize == 0)
12
@@ -482,7 +482,7 @@ dkimf_lua_setup_hook(void *ctx, const char *script, si
13
 	**  Register functions.
14
 	*/
15
 
16
-# if LUA_VERSION_NUM == 502
17
+# if (LUA_VERSION_NUM == 502 || LUA_VERSION_NUM == 503)
18
 	luaL_newlib(l, dkimf_lua_lib_setup);
19
 	lua_setglobal(l, "odkim");
20
 # else /* LUA_VERSION_NUM == 502 */
21
@@ -529,7 +529,7 @@ dkimf_lua_setup_hook(void *ctx, const char *script, si
22
 	/* import other globals */
23
 	dkimf_import_globals(ctx, l);
24
 
25
-# if LUA_VERSION_NUM == 502
26
+# if (LUA_VERSION_NUM == 502 || LUA_VERSION_NUM == 503)
27
 	switch (lua_load(l, dkimf_lua_reader, (void *) &io, name, NULL))
28
 # else /* LUA_VERSION_NUM == 502 */
29
 	switch (lua_load(l, dkimf_lua_reader, (void *) &io, name))
30
@@ -561,7 +561,11 @@ dkimf_lua_setup_hook(void *ctx, const char *script, si
31
 		io.lua_io_len = 0;
32
 		io.lua_io_alloc = 0;
33
 
34
+#if (LUA_VERSION_NUM == 503)
35
+		if (lua_dump(l, dkimf_lua_writer, &io, 0) == 0)
36
+#else
37
 		if (lua_dump(l, dkimf_lua_writer, &io) == 0)
38
+#endif
39
 		{
40
 			*keep = (void *) io.lua_io_script;
41
 			*funclen = io.lua_io_len;
42
@@ -637,7 +641,7 @@ dkimf_lua_screen_hook(void *ctx, const char *script, s
43
 	**  Register functions.
44
 	*/
45
 
46
-# if LUA_VERSION_NUM == 502
47
+# if (LUA_VERSION_NUM == 502 || LUA_VERSION_NUM == 503)
48
 	luaL_newlib(l, dkimf_lua_lib_screen);
49
 	lua_setglobal(l, "odkim");
50
 # else /* LUA_VERSION_NUM == 502 */
51
@@ -674,7 +678,7 @@ dkimf_lua_screen_hook(void *ctx, const char *script, s
52
 	/* import other globals */
53
 	dkimf_import_globals(ctx, l);
54
 
55
-# if LUA_VERSION_NUM == 502
56
+# if (LUA_VERSION_NUM == 502 || LUA_VERSION_NUM == 503)
57
 	switch (lua_load(l, dkimf_lua_reader, (void *) &io, name, NULL))
58
 # else /* LUA_VERSION_NUM == 502 */
59
 	switch (lua_load(l, dkimf_lua_reader, (void *) &io, name))
60
@@ -706,7 +710,11 @@ dkimf_lua_screen_hook(void *ctx, const char *script, s
61
 		io.lua_io_len = 0;
62
 		io.lua_io_alloc = 0;
63
 
64
+#if (LUA_VERSION_NUM == 503)
65
+		if (lua_dump(l, dkimf_lua_writer, &io, 0) == 0)
66
+#else
67
 		if (lua_dump(l, dkimf_lua_writer, &io) == 0)
68
+#endif
69
 		{
70
 			*keep = (void *) io.lua_io_script;
71
 			*funclen = io.lua_io_len;
72
@@ -782,7 +790,7 @@ dkimf_lua_stats_hook(void *ctx, const char *script, si
73
 	**  Register functions.
74
 	*/
75
 
76
-# if LUA_VERSION_NUM == 502
77
+# if (LUA_VERSION_NUM == 502 || LUA_VERSION_NUM == 503)
78
 	luaL_newlib(l, dkimf_lua_lib_stats);
79
 	lua_setglobal(l, "odkim");
80
 # else /* LUA_VERSION_NUM == 502 */
81
@@ -911,7 +919,7 @@ dkimf_lua_stats_hook(void *ctx, const char *script, si
82
 	/* import other globals */
83
 	dkimf_import_globals(ctx, l);
84
 
85
-# if LUA_VERSION_NUM == 502
86
+# if (LUA_VERSION_NUM == 502 || LUA_VERSION_NUM == 503)
87
 	switch (lua_load(l, dkimf_lua_reader, (void *) &io, name, NULL))
88
 # else /* LUA_VERSION_NUM == 502 */
89
 	switch (lua_load(l, dkimf_lua_reader, (void *) &io, name))
90
@@ -943,7 +951,11 @@ dkimf_lua_stats_hook(void *ctx, const char *script, si
91
 		io.lua_io_len = 0;
92
 		io.lua_io_alloc = 0;
93
 
94
+#if (LUA_VERSION_NUM == 503)
95
+		if (lua_dump(l, dkimf_lua_writer, &io, 0) == 0)
96
+#else
97
 		if (lua_dump(l, dkimf_lua_writer, &io) == 0)
98
+#endif
99
 		{
100
 			*keep = (void *) io.lua_io_script;
101
 			*funclen = io.lua_io_len;
102
@@ -1019,7 +1031,7 @@ dkimf_lua_final_hook(void *ctx, const char *script, si
103
 	**  Register functions.
104
 	*/
105
 
106
-# if LUA_VERSION_NUM == 502
107
+# if (LUA_VERSION_NUM == 502 || LUA_VERSION_NUM == 503)
108
 	luaL_newlib(l, dkimf_lua_lib_final);
109
 	lua_setglobal(l, "odkim");
110
 # else /* LUA_VERSION_NUM == 502 */
111
@@ -1148,7 +1160,7 @@ dkimf_lua_final_hook(void *ctx, const char *script, si
112
 	/* import other globals */
113
 	dkimf_import_globals(ctx, l);
114
 
115
-# if LUA_VERSION_NUM == 502
116
+# if (LUA_VERSION_NUM == 502 || LUA_VERSION_NUM == 503)
117
 	switch (lua_load(l, dkimf_lua_reader, (void *) &io, name, NULL))
118
 # else /* LUA_VERSION_NUM == 502 */
119
 	switch (lua_load(l, dkimf_lua_reader, (void *) &io, name))
120
@@ -1180,7 +1192,11 @@ dkimf_lua_final_hook(void *ctx, const char *script, si
121
 		io.lua_io_len = 0;
122
 		io.lua_io_alloc = 0;
123
 
124
+#if (LUA_VERSION_NUM == 503)
125
+		if (lua_dump(l, dkimf_lua_writer, &io, 0) == 0)
126
+#else
127
 		if (lua_dump(l, dkimf_lua_writer, &io) == 0)
128
+#endif
129
 		{
130
 			*keep = (void *) io.lua_io_script;
131
 			*funclen = io.lua_io_len;
132
@@ -1249,7 +1265,7 @@ dkimf_lua_db_hook(const char *script, size_t scriptlen
133
 		lua_pushstring(l, query);
134
 	lua_setglobal(l, "query");
135
 
136
-# if LUA_VERSION_NUM == 502
137
+# if (LUA_VERSION_NUM == 502 || LUA_VERSION_NUM == 503)
138
 	switch (lua_load(l, dkimf_lua_reader, (void *) &io, script, NULL))
139
 # else /* LUA_VERSION_NUM == 502 */
140
 	switch (lua_load(l, dkimf_lua_reader, (void *) &io, script))
141
@@ -1281,7 +1297,11 @@ dkimf_lua_db_hook(const char *script, size_t scriptlen
142
 		io.lua_io_len = 0;
143
 		io.lua_io_alloc = 0;
144
 
145
+#if (LUA_VERSION_NUM == 503)
146
+		if (lua_dump(l, dkimf_lua_writer, &io, 0) == 0)
147
+#else
148
 		if (lua_dump(l, dkimf_lua_writer, &io) == 0)
149
+#endif
150
 		{
151
 			*keep = (void *) io.lua_io_script;
152
 			*funclen = io.lua_io_len;

Return to bug 232953