Codebase list libhdate / 9309d92
[svn-upgrade] Integrating new upstream version, libhdate (1.4.11) Yaacov Zamir 15 years ago
64 changed file(s) with 4441 addition(s) and 624 deletion(s). Raw diff Collapse all Expand all
0 libhdate (1.4.11)
1
2 * Add Ruby bindings
3 * Add PHP bindings
4 * Add GPL notice to the example files (Bug report: Baruch Even)
5 * Add a patch to print todays date in hcal in bold (Patch: Patrik Nilsson)
6 * Fix documentation of files and structs (Bug report: Baruch Even)
7 * Update Swedish translation (Thanks: Patrik Nilsson)
8 * Fix hdate_get_utc_sun_time_deg
9 function only work in low altitudes (Bug report: Ido Kanner)
10 * Update pascal bindings and examples (Patch: Ido Kanner)
11
12 -- Yaacov Zamir <kzamir@wall.co.il> Saturday, 5 Jan 2008 22:00
13
014 libhdate (1.4.10)
115
216 * Move to GPL3 (COPYING, AUTHORS)
1529 - 30 shvat : Family day
1630 - 12 heshvan : rabin memorial day
1731 - 29 tamuz : zhabotinsky day
18
1932 * Changes to hdate command line utility
2033 - flag -j print the Julian day number
2134 - if argument is greater than 100000 it is asumed as Julian day number
156156 PA_VERSION = @PA_VERSION@
157157 PE_CFLAGS = @PE_CFLAGS@
158158 PE_MODULES_PATH = @PE_MODULES_PATH@
159 PH_CONFIG_PATH = @PH_CONFIG_PATH@
160 PH_MODULES_PATH = @PH_MODULES_PATH@
159161 PKG_CONFIG = @PKG_CONFIG@
160162 POSUB = @POSUB@
161163 PY_CFLAGS = @PY_CFLAGS@
162164 PY_MODULES_PATH = @PY_MODULES_PATH@
163165 PY_VERSION = @PY_VERSION@
164166 RANLIB = @RANLIB@
167 RU_CFLAGS = @RU_CFLAGS@
168 RU_MODULES_PATH = @RU_MODULES_PATH@
169 RU_VERSION = @RU_VERSION@
165170 SED = @SED@
166171 SET_MAKE = @SET_MAKE@
167172 SHELL = @SHELL@
175180 WITH_PASCAL_TRUE = @WITH_PASCAL_TRUE@
176181 WITH_PERL_FALSE = @WITH_PERL_FALSE@
177182 WITH_PERL_TRUE = @WITH_PERL_TRUE@
183 WITH_PHP_FALSE = @WITH_PHP_FALSE@
184 WITH_PHP_TRUE = @WITH_PHP_TRUE@
178185 WITH_PYTHON_FALSE = @WITH_PYTHON_FALSE@
179186 WITH_PYTHON_TRUE = @WITH_PYTHON_TRUE@
187 WITH_RUBY_FALSE = @WITH_RUBY_FALSE@
188 WITH_RUBY_TRUE = @WITH_RUBY_TRUE@
180189 XGETTEXT = @XGETTEXT@
181190 XGETTEXT_015 = @XGETTEXT_015@
182191 XGETTEXT_EXTRA_OPTIONS = @XGETTEXT_EXTRA_OPTIONS@
205214 exec_prefix = @exec_prefix@
206215 have_pascal = @have_pascal@
207216 have_perl = @have_perl@
217 have_php = @have_php@
218 have_php_config = @have_php_config@
208219 have_python = @have_python@
220 have_ruby = @have_ruby@
209221 have_swig = @have_swig@
210222 host = @host@
211223 host_alias = @host_alias@
0 SUBDIRS = python perl pascal
0 SUBDIRS = python perl pascal ruby php
128128 PA_VERSION = @PA_VERSION@
129129 PE_CFLAGS = @PE_CFLAGS@
130130 PE_MODULES_PATH = @PE_MODULES_PATH@
131 PH_CONFIG_PATH = @PH_CONFIG_PATH@
132 PH_MODULES_PATH = @PH_MODULES_PATH@
131133 PKG_CONFIG = @PKG_CONFIG@
132134 POSUB = @POSUB@
133135 PY_CFLAGS = @PY_CFLAGS@
134136 PY_MODULES_PATH = @PY_MODULES_PATH@
135137 PY_VERSION = @PY_VERSION@
136138 RANLIB = @RANLIB@
139 RU_CFLAGS = @RU_CFLAGS@
140 RU_MODULES_PATH = @RU_MODULES_PATH@
141 RU_VERSION = @RU_VERSION@
137142 SED = @SED@
138143 SET_MAKE = @SET_MAKE@
139144 SHELL = @SHELL@
147152 WITH_PASCAL_TRUE = @WITH_PASCAL_TRUE@
148153 WITH_PERL_FALSE = @WITH_PERL_FALSE@
149154 WITH_PERL_TRUE = @WITH_PERL_TRUE@
155 WITH_PHP_FALSE = @WITH_PHP_FALSE@
156 WITH_PHP_TRUE = @WITH_PHP_TRUE@
150157 WITH_PYTHON_FALSE = @WITH_PYTHON_FALSE@
151158 WITH_PYTHON_TRUE = @WITH_PYTHON_TRUE@
159 WITH_RUBY_FALSE = @WITH_RUBY_FALSE@
160 WITH_RUBY_TRUE = @WITH_RUBY_TRUE@
152161 XGETTEXT = @XGETTEXT@
153162 XGETTEXT_015 = @XGETTEXT_015@
154163 XGETTEXT_EXTRA_OPTIONS = @XGETTEXT_EXTRA_OPTIONS@
177186 exec_prefix = @exec_prefix@
178187 have_pascal = @have_pascal@
179188 have_perl = @have_perl@
189 have_php = @have_php@
190 have_php_config = @have_php_config@
180191 have_python = @have_python@
192 have_ruby = @have_ruby@
181193 have_swig = @have_swig@
182194 host = @host@
183195 host_alias = @host_alias@
203215 sharedstatedir = @sharedstatedir@
204216 sysconfdir = @sysconfdir@
205217 target_alias = @target_alias@
206 SUBDIRS = python perl pascal
218 SUBDIRS = python perl pascal ruby php
207219 all: all-recursive
208220
209221 .SUFFIXES:
00
1 EXTRA_DIST = Package.fpc hdate.pp hdate_class.pp fpc_README changelog
1 EXTRA_DIST = Package.fpc hdate.pp hdate_dyn_pascal.pp fpc_README changelog
22
33 if WITH_PASCAL
44
66
77 CLEANFILES = *.o *.ppu
88
9 all-am: hdate.o hdate_class.o
9 all-am: hdate.o hdate_dyn_pascal.o
1010
1111 hdate.o: hdate.pp
1212 fpc hdate.pp
1313
14 hdate_class.o: hdate_class.pp hdate.o
15 fpc hdate_class.pp
16
17 install-data-local:hdate_class.o hdate.o Package.fpc
14 hdate_dyn_pascal.o: hdate_dyn_pascal.pp hdate.o
15 fpc hdate_dyn_pascal.pp
16
17 install-data-local:hdate_dyn_pascal.o hdate.o
1818 $(mkinstalldirs) $(DESTDIR)$(PA_MODULES_PATH)/hdate
1919 $(INSTALL_DATA) hdate.o $(DESTDIR)$(PA_MODULES_PATH)/hdate/hdate.o
20 $(INSTALL_DATA) hdate_class.o $(DESTDIR)$(PA_MODULES_PATH)/hdate/hdate_class.o
20 $(INSTALL_DATA) hdate_dyn_pascal.o $(DESTDIR)$(PA_MODULES_PATH)/hdate/hdate_dyn_pascal.o
2121 $(INSTALL_DATA) hdate.ppu $(DESTDIR)$(PA_MODULES_PATH)/hdate/hdate.ppu
22 $(INSTALL_DATA) hdate_class.ppu $(DESTDIR)$(PA_MODULES_PATH)/hdate/hdate_class.ppu
22 $(INSTALL_DATA) hdate_dyn_pascal.ppu $(DESTDIR)$(PA_MODULES_PATH)/hdate/hdate_dyn_pascal.ppu
2323 $(INSTALL_DATA) fpc_README $(DESTDIR)$(PA_MODULES_PATH)/hdate/fpc_README
2424 $(INSTALL_DATA) Package.fpc $(DESTDIR)$(PA_MODULES_PATH)/hdate/Package.fpc
2525 endif
119119 PA_VERSION = @PA_VERSION@
120120 PE_CFLAGS = @PE_CFLAGS@
121121 PE_MODULES_PATH = @PE_MODULES_PATH@
122 PH_CONFIG_PATH = @PH_CONFIG_PATH@
123 PH_MODULES_PATH = @PH_MODULES_PATH@
122124 PKG_CONFIG = @PKG_CONFIG@
123125 POSUB = @POSUB@
124126 PY_CFLAGS = @PY_CFLAGS@
125127 PY_MODULES_PATH = @PY_MODULES_PATH@
126128 PY_VERSION = @PY_VERSION@
127129 RANLIB = @RANLIB@
130 RU_CFLAGS = @RU_CFLAGS@
131 RU_MODULES_PATH = @RU_MODULES_PATH@
132 RU_VERSION = @RU_VERSION@
128133 SED = @SED@
129134 SET_MAKE = @SET_MAKE@
130135 SHELL = @SHELL@
138143 WITH_PASCAL_TRUE = @WITH_PASCAL_TRUE@
139144 WITH_PERL_FALSE = @WITH_PERL_FALSE@
140145 WITH_PERL_TRUE = @WITH_PERL_TRUE@
146 WITH_PHP_FALSE = @WITH_PHP_FALSE@
147 WITH_PHP_TRUE = @WITH_PHP_TRUE@
141148 WITH_PYTHON_FALSE = @WITH_PYTHON_FALSE@
142149 WITH_PYTHON_TRUE = @WITH_PYTHON_TRUE@
150 WITH_RUBY_FALSE = @WITH_RUBY_FALSE@
151 WITH_RUBY_TRUE = @WITH_RUBY_TRUE@
143152 XGETTEXT = @XGETTEXT@
144153 XGETTEXT_015 = @XGETTEXT_015@
145154 XGETTEXT_EXTRA_OPTIONS = @XGETTEXT_EXTRA_OPTIONS@
168177 exec_prefix = @exec_prefix@
169178 have_pascal = @have_pascal@
170179 have_perl = @have_perl@
180 have_php = @have_php@
181 have_php_config = @have_php_config@
171182 have_python = @have_python@
183 have_ruby = @have_ruby@
172184 have_swig = @have_swig@
173185 host = @host@
174186 host_alias = @host_alias@
194206 sharedstatedir = @sharedstatedir@
195207 sysconfdir = @sysconfdir@
196208 target_alias = @target_alias@
197 EXTRA_DIST = Package.fpc hdate.pp hdate_class.pp fpc_README changelog
209 EXTRA_DIST = Package.fpc hdate.pp hdate_dyn_pascal.pp fpc_README changelog
198210 @WITH_PASCAL_TRUE@DEPS = $(top_builddir)/src/libhdate.la
199211 @WITH_PASCAL_TRUE@CLEANFILES = *.o *.ppu
200212 all: all-am
360372 uninstall uninstall-am uninstall-info-am
361373
362374
363 @WITH_PASCAL_TRUE@all-am: hdate.o hdate_class.o
375 @WITH_PASCAL_TRUE@all-am: hdate.o hdate_dyn_pascal.o
364376
365377 @WITH_PASCAL_TRUE@hdate.o: hdate.pp
366378 @WITH_PASCAL_TRUE@ fpc hdate.pp
367379
368 @WITH_PASCAL_TRUE@hdate_class.o: hdate_class.pp hdate.o
369 @WITH_PASCAL_TRUE@ fpc hdate_class.pp
370
371 @WITH_PASCAL_TRUE@install-data-local:hdate_class.o hdate.o Package.fpc
380 @WITH_PASCAL_TRUE@hdate_dyn_pascal.o: hdate_dyn_pascal.pp hdate.o
381 @WITH_PASCAL_TRUE@ fpc hdate_dyn_pascal.pp
382
383 @WITH_PASCAL_TRUE@install-data-local:hdate_dyn_pascal.o hdate.o
372384 @WITH_PASCAL_TRUE@ $(mkinstalldirs) $(DESTDIR)$(PA_MODULES_PATH)/hdate
373385 @WITH_PASCAL_TRUE@ $(INSTALL_DATA) hdate.o $(DESTDIR)$(PA_MODULES_PATH)/hdate/hdate.o
374 @WITH_PASCAL_TRUE@ $(INSTALL_DATA) hdate_class.o $(DESTDIR)$(PA_MODULES_PATH)/hdate/hdate_class.o
386 @WITH_PASCAL_TRUE@ $(INSTALL_DATA) hdate_dyn_pascal.o $(DESTDIR)$(PA_MODULES_PATH)/hdate/hdate_dyn_pascal.o
375387 @WITH_PASCAL_TRUE@ $(INSTALL_DATA) hdate.ppu $(DESTDIR)$(PA_MODULES_PATH)/hdate/hdate.ppu
376 @WITH_PASCAL_TRUE@ $(INSTALL_DATA) hdate_class.ppu $(DESTDIR)$(PA_MODULES_PATH)/hdate/hdate_class.ppu
388 @WITH_PASCAL_TRUE@ $(INSTALL_DATA) hdate_dyn_pascal.ppu $(DESTDIR)$(PA_MODULES_PATH)/hdate/hdate_dyn_pascal.ppu
377389 @WITH_PASCAL_TRUE@ $(INSTALL_DATA) fpc_README $(DESTDIR)$(PA_MODULES_PATH)/hdate/fpc_README
378390 @WITH_PASCAL_TRUE@ $(INSTALL_DATA) Package.fpc $(DESTDIR)$(PA_MODULES_PATH)/hdate/Package.fpc
379391 # Tell versions [3.59,3.63) of GNU make to not export all variables.
00 [package]
11 name=hdate
2 version=1.0.0
2 version=1.4.11
33 [require]
44 libc=y
55 packages_linux_m68k=
0 25/11/2005
1 - Added some constants and fixed comments according the orginal API file
0 25/01/2008
1 - Moved the class implementation to examples/binding
2 - Added better support for FPDoc
3 - Changed the demo for the class usage
4
5 11-12/01/2008
6 - Added support for newer API functions added at 1.3
7 - Added support for dynamic loading for the API.
8 - Added dynamic loading capabilities to the examples.
9 - Moved to GPL 3
10
11 25/11/2005
12 - Added some constants and fixed comments according the orginal API file
13
14 25/11/2005
15 - Added some constants and fixed comments according the orginal API file
216
317 27/05/2005
4 - Created a Changelog.
18 - Created a Changelog.
519
620 19-21/05/2005
7 - hdate_class.pp was created.
8 - Made changes for Free Pascal 2 support on with the units.
21 - hdate_class.pp was created.
22 - Made changes for Free Pascal 2 support on with the units.
923
1024 13/03/2005
11 - Bug fix in hdate.pp - Added {$PACKRECORDS C}
25 - Bug fix in hdate.pp - Added {$PACKRECORDS C}
1226
1327 10-11/03/2005
14 - hdate.pp was created.
15 - hdate_obj.pp was created.
28 - hdate.pp was created.
29 - hdate_obj.pp was created.
44 It is using the source code from Amos Shapir's hdate package fixed and patched by Nadav Har'El.
55 The Torah reading sequence is from tables by Zvi Har'El.
66
7 The LibHdate is GPL library written by Kobi Zamir <kobi_zamir@yahoo.com> and can be found at http://libhdate.sourceforge.net/ .
7 The LibHdate is GPL library written by Kobi Zamir <kzamir@walla.co.il> and can be found at http://libhdate.sourceforge.net/ .
88
9 The current version of LibHDate is 1.2.1 and contains a Free Pascal binding only that was written by Ido Kanner <idokan@gmail.com>.
9 The current version of LibHDate is 1.4.10 and contains a Free Pascal binding only that was written by Ido Kanner <idokan@gmail.com>.
1010
1111 Existed Files:
12 README - This file.
13 licence - A copy of the GPL license.
14 src/ctypes.pp - A unit for making C like integer and floating points variable type.
15 src/hdate.pp - The main low level API of LibHdate binding.
16 src/hdate_obj.pp - An Object Oriented implementation for the hdate.pp API.
17 src/hdate_obj_demo.pp - An example for the use of the Object Oriented unit.
18 src/hdate_class.pp - A self made Object Oriented implementation for the LibHdate API.
12 /bindings/pascal/fpc_README - This file.
13
14 COPYING - A copy of the GPL license.
15
16 examples/bindings/pascal/hdate_obj.pp - An Object Oriented implementation for the hdate.pp API.
17 examples/bindings/pascal/hdate_obj_demo.pp - An example for the use of the Object Oriented unit.
18 examples/bindings/pascal/hdate_class.pp - A self made Object Oriented implementation for the LibHdate API.
19
20 bindings/pascal/
21 bindings/pascal/hdate.pp - The main low level API of LibHdate binding.
22 bindings/pascal/hdate_dyn_pascal.pp - A dynamic linking library.
23
1924
2025 Compiling
2126 =========
2328 The ctypes.pp unit was taken from FPC 1.9.8 version and was modified to contain also some floating point C equivalent.
2429 The FPC version 2.0 have the floating points definition. If you are using FPC version 2.0 or above please remove the unit.
2530
26 Add the hdate.pp and the hdate_obj.pp (or thier .ppu files after compilation) to the path of fpc.cfg in order to use
27 the units globally with all of your applications.
31 Add the hdate.pp and the hdate_obj.pp (or thier .ppu files after compilation) to the path of fpc.cfg in order to use the units globally with all of your applications.
32
33 It is recommanded to use FPC 2.2.0 or above for the newer version of this library.
2834
2935 =========================================================================
3036 the old README from version 1.1.1
00 (* libhdate
1 Copyright 2004-2005 Yaacov Zamir <kzamir@walla.co.il>
2 Copyright 2005 Ido Kanner <idokan@gmail.com>
1
2 Copyright (C) 1984-2003 Amos Shapir, 2004-2007 Yaacov Zamir <kzamir@walla.co.il>
3 Copyright (C) 2005-2008 Ido Kanner <idokan@gmail.com>
34
45 This program is free software; you can redistribute it and/or modify
56 it under the terms of the GNU General Public License as published by
1617 Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
1718
1819 History:
20 11/01/2008 - Added support for 1.3 API and cleaned the calling.
1921 25/11/2005 - Added some constants and fixed comments according the orginal API file
2022 13/03/2005 - Bug Fixed Added {$PACKRECORDS C}
21 10-11/03/2005 - Initial Translation of version 0.31.0
22 *)
23 {$MODE OBJFPC}{$PACKRECORDS C}
23 10-11/03/2005 - Initial Translation of version 0.31.0
24 *)
25 {$MODE FPC}{$PACKRECORDS C}
26 {$LINKLIB hdate}
2427
2528 unit hdate;
2629
2831 uses cTypes;
2932
3033 const
34 // the global name of the hdate library: <b>DEPERCATED</b>
3135 LIBHDATE_LIBRARY_NAME = 'hdate';
3236
3337 (** @def HDATE_DIASPORA_FLAG
5458 { Base structore for hebrew dates }
5559
5660 type
61 // A pointer to the Thdate_struct record
5762 Phdate_struct = ^Thdate_struct;
5863 Thdate_struct = record
59 hd_day : cInt; //The number of day in the hebrew month (1..31).
60 hd_mon : cInt; //The number of the hebrew month 1..14 (1 - tishre, 13 - adar 1, 14 - adar 2).
61 hd_year : cInt; //The number of the hebrew year.
62 gd_day : cInt; //The number of the day in the month. (1..31)
63 gd_mon : cInt; //The number of the month 1..12 (1 - jan).
64 gd_year : cInt; //The number of the year.
65 hd_dw : cInt; //The day of the week 1..7 (1 - sunday).
66 hd_size_of_year : cInt; //The length of the year in days.
67 hd_new_year_dw : cInt; //The week day of Hebrew new year.
68 hd_year_type : cInt; //The number type of year.
69 hd_jd : cInt; //The Julian day number
70 hd_days : cInt; //The number of days passed since 1 tishrey
71 hd_weeks : cInt; //The number of weeks passed since 1 tishrey
64 //The number of day in the hebrew month (1..31).
65 hd_day : cInt;
66 //The number of the hebrew month 1..14 (1 - tishre, 13 - adar 1, 14 - adar 2).
67 hd_mon : cInt;
68 //The number of the hebrew year.
69 hd_year : cInt;
70 //The number of the day in the month. (1..31)
71 gd_day : cInt;
72 //The number of the month 1..12 (1 - jan).
73 gd_mon : cInt;
74 //The number of the year.
75 gd_year : cInt;
76 //The day of the week 1..7 (1 - sunday).
77 hd_dw : cInt;
78 //The length of the year in days.
79 hd_size_of_year : cInt;
80 //The week day of Hebrew new year.
81 hd_new_year_dw : cInt;
82 //The number type of year.
83 hd_year_type : cInt;
84 //The Julian day number
85 hd_jd : cInt;
86 //The number of days passed since 1 tishrey
87 hd_days : cInt;
88 //The number of weeks passed since 1 tishrey
89 hd_weeks : cInt;
7290 end;
7391 (********************************************************************************)
7492 (********************************************************************************)
82100 @param y Year in 4 digits e.g. 2001
83101 @return pointer to this hdate struct
84102 *)
85
86103 function hdate_set_gdate (h : Phdate_struct; d, m, y : cInt) : Phdate_struct;
87 cdecl external LIBHDATE_LIBRARY_NAME name 'hdate_set_gdate';
104 cdecl; external;
88105
89106 (**
90107 @brief compute date structure from the Hebrew date
95112 @param y Year in 4 digits e.g. 5731
96113 @return pointer to this hdate struct
97114 *)
98
99115 function hdate_set_hdate (h : Phdate_struct; d, m, y : cInt) : Phdate_struct;
100 cdecl external LIBHDATE_LIBRARY_NAME name 'hdate_set_hdate';
116 cdecl; external;
101117
102118 (**
103119 @brief compute date structure from the Julian day
107123 @return pointer to this hdate struct
108124 *)
109125 function hdate_set_jd (h : Phdate_struct; jd : cInt) : Phdate_struct;
110 cdecl external LIBHDATE_LIBRARY_NAME name 'hdate_set_jd';
126 cdecl; external;
111127
112128 (*************************************************************)
113129 (*************************************************************)
124140 @return a static string of foramted date
125141 *)
126142 function hdate_get_format_date (h : Phdate_struct; diaspora, s : cInt) : PChar;
127 cdecl external LIBHDATE_LIBRARY_NAME name 'hdate_get_format_date';
143 cdecl; external;
128144
129145 (**
130146 @brief get the number of hebrew parasha.
135151 (55 trow 61 are joined strings e.g. Vayakhel Pekudei)
136152 *)
137153 function hdate_get_parasha (h : Phdate_struct; diaspora : cInt) : cInt;
138 cdecl external LIBHDATE_LIBRARY_NAME name 'hdate_get_parasha';
154 cdecl; external;
139155
140156 (**
141157 @brief get the number of hebrew holyday.
145161 @return the number of holyday.
146162 *)
147163 function hdate_get_holyday (h : Phdate_struct; diaspora : cInt) : cInt;
148 cdecl external LIBHDATE_LIBRARY_NAME name 'hdate_get_holyday';
164 cdecl; external;
149165
150166 (*************************************************************)
151167 (*************************************************************)
158174 @attention ( 0 < n < 10000)
159175 *)
160176 function hdate_get_int_string (n : cInt) : PChar;
161 cdecl external LIBHDATE_LIBRARY_NAME name 'hdate_get_int_string';
177 cdecl; external;
162178
163179 (**
164180 @brief get name of week day.
169185 @return a static string of the day of the week
170186 *)
171187 function hdate_get_day_string (day : cInt; s : cInt) : PChar;
172 cdecl external LIBHDATE_LIBRARY_NAME name 'hdate_get_day_string';
188 cdecl; external;
173189
174190 (**
175191 @brief name of month.
179195 @return a static string of month name
180196 *)
181197 function hdate_get_month_string (month : cInt; s : cInt) : PChar;
182 cdecl external LIBHDATE_LIBRARY_NAME name 'hdate_get_month_string';
198 cdecl; external;
183199
184200 (**
185201 @brief name of hebrew month.
190206 @return a static string of month name
191207 *)
192208 function hdate_get_hebrew_month_string (month : cInt; s : cInt) : PChar;
193 cdecl external LIBHDATE_LIBRARY_NAME name 'hdate_get_hebrew_month_string';
209 cdecl; external;
194210
195211 (**
196212 @brief name of hebrew holyday.
200216 @return a static string of holyday name
201217 *)
202218 function hdate_get_holyday_string (holyday, s : cInt) : PChar;
203 cdecl external LIBHDATE_LIBRARY_NAME name 'hdate_get_holyday_string';
219 cdecl; external;
204220
205221 (**
206222 @brief name of parasha
211227 @return a static string of parasha name
212228 *)
213229 function hdate_get_parasha_string (parasha, s : cInt) : PChar;
214 cdecl external LIBHDATE_LIBRARY_NAME name 'hdate_get_parasha_string';
230 cdecl; external;
215231
216232 (*************************************************************)
217233 (*************************************************************)
223239 @return the number of holyday type.
224240 *)
225241 function hdate_get_holyday_type (holyday : cInt) : cInt;
226 cdecl external LIBHDATE_LIBRARY_NAME name 'hdate_get_holyday_type';
242 cdecl; external;
227243
228244 (**
229245 @brief size of hebrew year in days.
232248 @return size of Hebrew year
233249 *)
234250 function hdate_get_size_of_hebrew_year (hebrew_year : cInt) : cInt;
235 cdecl external LIBHDATE_LIBRARY_NAME name 'hdate_get_size_of_hebrew_year';
251 cdecl; external;
236252
237253 (*************************************************************)
238254 (*************************************************************)
246262 @return Number of days since 3,1,3744
247263 *)
248264 function hdate_days_from_3744 (hebrew_year : cInt) : cInt;
249 cdecl external LIBHDATE_LIBRARY_NAME name 'hdate_days_from_3744';
265 cdecl; external;
250266
251267 (**
252268 @brief Return Hebrew year type based on size and first week day of year.
256272 @return the number for year type (1..14)
257273 *)
258274 function hdate_get_year_type (size_of_year, new_year_dw : cInt) : cInt;
259 cdecl external LIBHDATE_LIBRARY_NAME name 'hdate_get_year_type';
275 cdecl; external;
260276
261277 (**
262278 @brief Compute Julian day from Gregorian date
269285 @return the julian day number
270286 *)
271287 function hdate_gdate_to_jd (day, month, year : cInt) : cInt;
272 cdecl external LIBHDATE_LIBRARY_NAME name 'hdate_gdate_to_jd';
288 cdecl; external;
273289
274290 (**
275291 @brief Compute Julian day from Hebrew day, month and year
284300 @return the julian day number
285301 *)
286302 function hdate_hdate_to_jd (day, month, year : cInt; jd_tishrey1, jd_tishrey1_next_year : pcInt) : cInt;
287 cdecl external LIBHDATE_LIBRARY_NAME name 'hdate_hdate_to_jd';
303 cdecl; external;
288304
289305 (**
290306 @brief Converting from the Julian day to the Gregorian date
297313 @param year return Year in 4 digits e.g. 2001
298314 *)
299315 procedure hdate_jd_to_gdate (jd : cInt; day, month, year : pcInt);
300 cdecl external LIBHDATE_LIBRARY_NAME name 'hdate_jd_to_gdate';
316 cdecl; external;
301317
302318 (**
303319 @brief Converting from the Julian day to the Hebrew day
312328 @param jd_tishrey1_next_year return the julian number of 1 Tishrey next year
313329 *)
314330 procedure hdate_jd_to_hdate (jd : cInt; day, month, year, jd_tishrey1, jd_tishrey1_next_year : pcInt);
315 cdecl external LIBHDATE_LIBRARY_NAME name 'hdate_jd_to_hdate';
331 cdecl; external;
316332
317333 (*************************************************************)
318334 (*************************************************************)
326342 @return the days from 1 jan
327343 *)
328344 function hdate_get_day_of_year (day, month, year : cInt) : cInt;
329 cdecl external LIBHDATE_LIBRARY_NAME name 'hdate_get_day_of_year';
345 cdecl; external;
330346
331347 (**
332348 @brief utc sunrise/set time for a gregorian date
342358 @param sunset return the utc sunset in minutes after midnight (00:00)
343359 *)
344360 procedure hdate_get_utc_sun_time (day, month, year : cInt; latitude, longitude : cDouble; sunrise, sunset : pcInt);
345 cdecl external LIBHDATE_LIBRARY_NAME name 'hdate_get_utc_sun_time';
361 cdecl; external;
346362
347363 (*************************************************************)
348364 (*************************************************************)
354370 @return the Gregorian day of the month, 1..31.
355371 *)
356372 function hdate_get_gday (h : Phdate_struct) : cInt;
357 cdecl external LIBHDATE_LIBRARY_NAME name 'hdate_get_gday';
373 cdecl; external;
358374
359375 (**
360376 @brief get the Gregorian month
363379 @return the Gregorian month, jan = 1.
364380 *)
365381 function hdate_get_gmonth (h : Phdate_struct) : cInt;
366 cdecl external LIBHDATE_LIBRARY_NAME name 'hdate_get_gmonth';
382 cdecl; external;
367383
368384 (**
369385 @brief get the Gregorian year
372388 @return the Gregorian year.
373389 *)
374390 function hdate_get_gyear (h : Phdate_struct) : cInt;
375 cdecl external LIBHDATE_LIBRARY_NAME name 'hdate_get_gyear';
391 cdecl; external;
376392
377393 (**
378394 @brief get the Hebrew day of the month
381397 @return the Hebrew day of the month, 1..30.
382398 *)
383399 function hdate_get_hday (h : Phdate_struct) : cInt;
384 cdecl external LIBHDATE_LIBRARY_NAME name 'hdate_get_hday';
400 cdecl; external;
385401
386402 (**
387403 @brief get the Hebrew month
390406 @return the Hebrew month, Tishery = 1 .. Adar I =13, Adar II = 14.
391407 *)
392408 function hdate_get_hmonth (h : Phdate_struct) : cInt;
393 cdecl external LIBHDATE_LIBRARY_NAME name 'hdate_get_hmonth';
409 cdecl; external;
394410
395411 (**
396412 @brief get the Hebrew year
399415 @return the Hebrew year.
400416 *)
401417 function hdate_get_hyear (h : Phdate_struct) : cInt;
402 cdecl external LIBHDATE_LIBRARY_NAME name 'hdate_get_hyear';
418 cdecl; external;
403419
404420 (**
405421 @brief get the day of the week
408424 @return the the day of the week.
409425 *)
410426 function hdate_get_day_of_the_week (h : Phdate_struct) : cInt;
411 cdecl external LIBHDATE_LIBRARY_NAME name 'hdate_get_day_of_the_week';
427 cdecl; external;
412428
413429 (**
414430 @brief get the size of the hebrew year
417433 @return the the size of the hebrew year.
418434 *)
419435 function hdate_get_size_of_year (h : Phdate_struct) : cInt;
420 cdecl external LIBHDATE_LIBRARY_NAME name 'hdate_get_size_of_year';
436 cdecl; external;
421437
422438 (**
423439 @brief get the new year day of the week
426442 @return the the new year day of the week.
427443 *)
428444 function hdate_get_new_year_day_of_the_week (h : Phdate_struct) : cInt;
429 cdecl external LIBHDATE_LIBRARY_NAME name 'hdate_get_new_year_day_of_the_week';
445 cdecl; external;
430446
431447 (**
432448 @brief get the Julian day number
435451 @return the Julian day number.
436452 *)
437453 function hdate_get_julian (h : Phdate_struct) : cInt;
438 cdecl external LIBHDATE_LIBRARY_NAME name 'hdate_get_julian';
454 cdecl; external;
439455
440456 (**
441457 @brief get the number of days passed since 1 tishrey
444460 @return the number of days passed since 1 tishrey.
445461 *)
446462 function hdate_get_days (h : Phdate_struct) : cInt;
447 cdecl external LIBHDATE_LIBRARY_NAME name 'hdate_get_days';
463 cdecl; external;
448464
449465 (**
450466 @brief get the number of weeks passed since 1 tishrey
453469 @return the number of weeks passed since 1 tishrey.
454470 *)
455471 function hdate_get_weeks (h : Phdate_struct) : cInt;
456 cdecl external LIBHDATE_LIBRARY_NAME name 'hdate_get_weeks';
472 cdecl; external;
457473
458474 (*************************************************************)
459475 (*************************************************************)
464480 @return a new hdate object
465481 *)
466482 function new_hdate : Phdate_struct;
467 cdecl external LIBHDATE_LIBRARY_NAME name 'new_hdate';
483 cdecl; external;
468484
469485 (**
470486 @brief delete an hdate struct object.
472488 @param h pointer this hdate struct.
473489 *)
474490 function delete_hdate (h : Phdate_struct) : Phdate_struct;
475 cdecl external LIBHDATE_LIBRARY_NAME name 'delete_hdate';
491 cdecl; external;
476492
477493 (*************************************************************)
478494 (*************************************************************)
483499 @return a a static string, with the package name and version
484500 *)
485501 function hdate_get_version_string : PChar;
486 cdecl external LIBHDATE_LIBRARY_NAME name 'hdate_get_version_string';
502 cdecl; external;
487503
488504 (**
489505 @brief Return a static string, with the name of translator
491507 @return a a static string, with the name of translator
492508 *)
493509 function hdate_get_translator_string : PChar;
494 cdecl external LIBHDATE_LIBRARY_NAME name 'hdate_get_translator_string';
510 cdecl; external;
511
512 (**
513 @brief utc sun times for altitude at a gregorian date
514
515 @param day this day of month
516 @param month this month
517 @param year this year
518 @param latitude latitude to use in calculations
519 @param longitude longitude to use in calculations
520 @param deg degrees of sun's altitude (0 - Zenith .. 90 - Horizon)
521 @param sunrise return the utc sunrise in minutes
522 @param sunset return the utc sunset in minutes
523 *)
524 procedure hdate_get_utc_sun_time_deg(day, month, year : cint; latitude, longitude, deg : cdouble; sunrise, sunset : pcint);
525 cdecl; external;
526
527
528 (**
529 @brief utc sunrise/set time for a gregorian date
530
531 @param day this day of month
532 @param month this month
533 @param year this year
534 @param longitude longitude to use in calculations
535 @param latitude latitude to use in calculations
536 @param sun_hour return the length of shaa zmanit in minutes
537 @param first_light return the utc alut ha-shachar in minutes
538 @param talit return the utc tphilin and talit in minutes
539 @param sunrise return the utc sunrise in minutes
540 @param midday return the utc midday in minutes
541 @param sunset return the utc sunset in minutes
542 @param first_stars return the utc tzeit hacochavim in minutes
543 @param three_stars return the utc shlosha cochavim in minutes
544 *)
545 procedure hdate_get_utc_sun_time_full (day, month, year : cint;
546 latitude, longitude : cdouble;
547 sun_hour, first_light, talit, sunrise, midday, sunset,
548 first_stars, three_stars : pcint);
549 cdecl; external;
550
551
495552
496553 implementation
497554
+0
-321
current/bindings/pascal/hdate_class.pp less more
0 {
1 This unit create a Pascal object oriented class for libhdate.
2 This unit is created as a true object oriented class.
3
4 Copyright 2005 Ido Kanner <idokan@gmail.com>
5
6 This program is free software; you can redistribute it and/or modify
7 it under the terms of the GNU General Public License as published by
8 the Free Software Foundation; either version 2 of the License, or
9 (at your option) any later version.
10
11 This program is distributed in the hope that it will be useful,
12 but WITHOUT ANY WARRANTY; without even the implied warranty of
13 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 GNU Library General Public License for more details.
15
16 You should have received a copy of the GNU General Public License
17 along with this program; if not, write to the Free Software
18 Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
19
20 History:
21 19-21/05/2005 - Initial creation
22 }
23 {$IFDEF FPC}
24 {$MODE OBJFPC} {$H+}
25 {$ELSE}
26 {$Warning 'This code was tested with Free Pascal Only.'}
27 {$ENDIF}
28 unit hdate_class;
29
30 interface
31 uses hdate, SysUtils;
32
33 type
34 THdateClass = class
35 private
36 fh : Phdate_struct;
37 FToDestroy : Boolean;
38 fJulianDay : LongInt;
39 fDiaspora : Boolean;
40 fHolyday,
41 fHolydayType : LongInt;
42 fParasha : LongInt;
43 fHebrewDay,
44 fHebrewYear : String;
45
46 procedure InitValue;
47
48 procedure SetHebDay (Value : LongInt);
49 procedure SetGregDay (Value : LongInt);
50 procedure SetJulianDay (Value : LongInt);
51 procedure SetHebMonth (Value : LongInt);
52 procedure SetGregMonth (Value : LongInt);
53 procedure SetGregYear (Value : LongInt);
54 procedure SetHebYear (Value : LongInt);
55 procedure SetDiaspora (Value : Boolean);
56
57 function GetGregDay : LongInt;
58 function GetGregMonth : LongInt;
59 function GetGregYear : LongInt;
60 function GetHebDay : LongInt;
61 function GetHebMonth : LongInt;
62 function GetHebYear : LongInt;
63 public
64 constructor Create; virtual; overload;
65 constructor Create (hDateRec : Phdate_struct); virtual; overload;
66 destructor Destroy; override;
67
68 procedure Assign (Source : THdateClass); virtual;
69
70 function get_format_date (s : LongInt) : String;
71 function get_day_of_week_string (s : LongInt) : String;
72 function get_month_string (s : LongInt) : String;
73 function get_hebrew_month_string (s : LongInt) : String;
74 function get_holyday_string (s : LongInt) : String;
75 function get_parasha_string (s : LongInt) : String;
76 function GetDayOfWeek : LongInt;
77 function get_size_of_year : LongInt;
78 function get_new_year_day_of_the_week : LongInt;
79 function get_days : LongInt;
80 function get_weeks : LongInt;
81 function get_sunrise (latitude, longitude : Double; tz : LongInt) : LongInt;
82 function get_sunset (latitude, longitude : Double; tz : LongInt) : LongInt;
83
84 property Days : LongInt read get_days;
85 property DayOfWeek : LongInt read GetDayOfWeek;
86 property HebrewDay : String read fHebrewDay;
87 property HebrewYear : String read fHebrewYear;
88 property Holyday : LongInt read fHolyday;
89 property HolydayType : LongInt read fHolydayType;
90 property NewYearDayOfWeek : LongInt read get_new_year_day_of_the_week;
91 property Parasha : LongInt read fParasha;
92 property Weeks : LongInt read get_weeks;
93 property YearSize : Longint read get_size_of_year;
94 published
95 property HebDay : LongInt read GetHebDay write SetHebDay;
96 property GregDay : LongInt read GetGregDay write SetGregDay;
97 property Diaspora : Boolean read fDiaspora write SetDiaspora default True;
98 property JulianDay : LongInt read fJulianDay write SetJulianDay;
99 property HebMonth : LongInt read GetHebMonth write SetHebMonth;
100 property GregMonth : LongInt read GetGregMonth write SetGregMonth;
101 property ToDestroy : Boolean read FToDestroy write fToDestroy default True;
102 property GregYear : LongInt read GetGregYear write SetGregYear;
103 property HebYear : LongInt read GetHebYear write SetHebYear;
104 end;
105
106 implementation
107 uses DateUtils, cTypes;
108
109 procedure THdateClass.InitValue;
110 var
111 ADay, AMonth, AYear : Word;
112 begin
113 DecodeDate(SysUtils.Now, AYear, AMonth, ADay);
114
115 hdate_set_gdate (Fh, ADay, AMonth, AYear);
116
117 hdate_set_hdate (fh, hdate_get_hday (fh), hdate_get_hmonth (fh), hdate_get_hyear (fh));
118
119 fHebrewDay := StrPas (hdate_get_int_string (fh^.hd_day));
120 fHebrewYear := StrPas (hdate_get_int_string (fh^.hd_year));
121
122 SetJulianDay (hdate_gdate_to_jd (ADay, AMonth, AYear));
123 SetDiaspora (True);
124 end;
125
126 constructor THdateClass.Create;
127 begin
128 fh := nil;
129 fh := new_hdate;
130 fToDestroy := True;
131 InitValue;
132 end;
133
134 constructor THdateClass.Create (hDateRec : Phdate_struct);
135 begin
136 fh := hDateRec;
137 fToDestroy := False;
138 InitValue;
139 end;
140
141 destructor THdateClass.Destroy;
142 begin
143 if fToDestroy then
144 delete_hdate (fh);
145
146 inherited;
147 end;
148
149 procedure THdateClass.SetHebDay (Value : LongInt);
150 begin
151 hdate_set_hdate (Fh, Value, GetHebMonth, GetHebYear);
152 fHebrewDay := StrPas (hdate_get_int_string (fh^.hd_day));
153 end;
154
155 procedure THdateClass.SetGregDay (Value : LongInt);
156 begin
157 hdate_set_gdate (fh, Value, GetGregMonth, GetGregYear);
158 end;
159
160 procedure THdateClass.SetJulianDay (Value : LongInt);
161 begin
162 fJulianDay := Value;
163 hdate_set_jd (fh, fJulianDay);
164 end;
165
166 procedure THdateClass.SetHebMonth (Value : LongInt);
167 begin
168 hdate_set_hdate (Fh, GetHebDay, Value, GetHebYear);
169 end;
170
171 procedure THdateClass.SetGregMonth (Value : LongInt);
172 begin
173 hdate_set_gdate (fh, GetGregDay, Value, GetGregYear);
174 end;
175
176 procedure THdateClass.SetHebYear (Value : LongInt);
177 begin
178 hdate_set_hdate (fh, GetHebDay, GetGregMonth, Value);
179 fHebrewYear := StrPas (hdate_get_int_string (fh^.hd_year));
180 end;
181
182 procedure THdateClass.SetGregYear (Value : LongInt);
183 begin
184 hdate_set_gdate (fh, GetGregDay, GetGregMonth, Value);
185 end;
186
187 procedure THdateClass.SetDiaspora (Value : Boolean);
188 begin
189 fDiaspora := Value;
190 fHolyday := hdate_get_holyday (fh, cInt(FDiaspora));
191 fHolydayType := hdate_get_holyday_type (fHolyday);
192 fParasha := hdate_get_parasha (fh, cInt(fDiaspora));
193 end;
194
195 function THdateClass.GetGregDay : LongInt;
196 begin
197 Result := hdate_get_gday (fh);
198 end;
199
200 function THdateClass.GetGregMonth : LongInt;
201 begin
202 Result := hdate_get_gmonth (fh);
203 end;
204
205 function THdateClass.GetGregYear : LongInt;
206 begin
207 Result := hdate_get_gyear (fh);
208 end;
209
210 function THdateClass.GetHebDay : LongInt;
211 begin
212 Result := hdate_get_hday (fh);
213 end;
214
215 function THdateClass.GetHebMonth : LongInt;
216 begin
217 Result := hdate_get_hmonth (fh);
218 end;
219
220 function THdateClass.GetHebYear : LongInt;
221 begin
222 Result :=hdate_get_hyear (fh);
223 end;
224
225 procedure THdateClass.Assign (Source : THdateClass);
226 begin
227 if (not Assigned(Source)) then
228 begin
229 raise Exception.Create ('Source is not allocated.');
230 end;
231
232 Assert (Assigned(Source), 'Source is not allocated.'); // Should never happned ... but just in case...
233
234 fToDestroy := Source.ToDestroy;
235
236 HebDay := Source.HebDay;
237 GregDay := Source.GregDay;
238 HebMonth := Source.HebMonth;
239 GregMonth := Source.GregMonth;
240 HebYear := Source.HebYear;
241 GregYear := Source.GregYear;
242
243 SetJulianDay (Source.JulianDay);
244 SetDiaspora (Source.Diaspora);
245 end;
246
247 function THdateClass.get_format_date (s : LongInt) : String;
248 begin
249 Result := StrPas (hdate_get_format_date (fh, cInt(fDiaspora), s));
250 end;
251
252 function THdateClass.get_day_of_week_string (s : LongInt) : String;
253 begin
254 Result := StrPas (hdate_get_day_string (fh^.hd_dw, s));
255 end;
256
257 function THdateClass.get_month_string (s : LongInt) : String;
258 begin
259 Result := StrPas (hdate_get_month_string (fh^.gd_mon, s));
260 end;
261
262 function THdateClass.get_hebrew_month_string (s : LongInt) : String;
263 begin
264 Result := StrPas (hdate_get_hebrew_month_string (fh^.hd_mon, s));
265 end;
266
267 function THdateClass.get_holyday_string (s : LongInt) : String;
268 begin
269 Result := StrPas (hdate_get_holyday_string (fHolyday, s));
270 end;
271
272 function THdateClass.get_parasha_string (s : LongInt) : String;
273 begin
274 Result := StrPas (hdate_get_parasha_string (fParasha, s));
275 end;
276
277 function THdateClass.GetDayOfWeek : LongInt;
278 begin
279 Result := hdate_get_day_of_the_week (fh);
280 end;
281
282 function THdateClass.get_size_of_year : LongInt;
283 begin
284 Result := hdate_get_size_of_year (fh);
285 end;
286
287 function THdateClass.get_new_year_day_of_the_week : LongInt;
288 begin
289 Result := hdate_get_new_year_day_of_the_week (fh);
290 end;
291
292 function THdateClass.get_days : LongInt;
293 begin
294 Result := hdate_get_days (fh);
295 end;
296
297 function THdateClass.get_weeks : LongInt;
298 begin
299 Result := hdate_get_weeks (fh);
300 end;
301
302 function THdateClass.get_sunrise (latitude, longitude : Double; tz : LongInt) : LongInt;
303 var
304 sunrise,
305 sunset : cInt;
306 begin
307 hdate_get_utc_sun_time (fh^.gd_day, fh^.gd_mon, fh^.gd_year, latitude, longitude, @sunrise, @sunset);
308 Result := sunrise + tz * 60;
309 end;
310
311 function THdateClass.get_sunset (latitude, longitude : Double; tz : LongInt) : LongInt;
312 var
313 sunrise,
314 sunset : cInt;
315 begin
316 hdate_get_utc_sun_time (fh^.gd_day, fh^.gd_mon, fh^.gd_year, latitude, longitude, @sunrise, @sunset);
317 Result := sunset + tz * 60;
318 end;
319
320 end.
0
1 (* libhdate
2 Copyright (C) 1984-2003 Amos Shapir, 2004-2007 Yaacov Zamir <kzamir@walla.co.il>
3 Copyright (C) 2008 Ido Kanner <idokan@gmail.com>
4
5 This program is free software: you can redistribute it and/or modify
6 it under the terms of the GNU General Public License as published by
7 the Free Software Foundation, either version 3 of the License, or
8 (at your option) any later version.
9
10 This program is distributed in the hope that it will be useful,
11 but WITHOUT ANY WARRANTY; without even the implied warranty of
12 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 GNU General Public License for more details.
14
15 You should have received a copy of the GNU General Public License
16 along with this program. If not, see <http://www.gnu.org/licenses/>.
17
18 History:
19 25/01/2008 - Fixed some logical bugs.
20 - Added FPDoc support
21 12/01/2008 - Added support for dynamic loading for the library
22 *)
23
24 Unit hdate_dyn_pascal;
25
26 {$IFDEF FPC}
27 {$MODE FPC}
28 {$PACKRECORDS C}
29 {$CALLING cdecl}
30 {$ENDIF}
31
32
33 (*
34 Auto load means that we are loading the functions when the unit is loaded.
35 Disable this define will mean that you should load and unload it by hand, using the needed procedures
36 *)
37 {$DEFINE AUTO_LOAD}
38
39 Interface
40
41 {$IFDEF FPC}
42
43 Uses
44 ctypes;
45 {$ENDIF}
46
47 { Load and assign the hdate library dynamiclly
48 Note: If AUTO_LOAD is defined, then no need to use this procedure
49 }
50 Procedure hdate_init;
51
52 { Free the memory from the hdate library loading
53 Note: If AUTO_LOAD is defined, then no need to use this procedure
54 }
55 Procedure hdate_done;
56
57 { Return true if the library was was loaded, or false if not }
58 Function IsLoaded : Boolean;
59
60 Const
61 {$IFDEF UNIX}
62 LIBHDATE_LIBRARY_NAME = 'libhdate.so';
63 {$ELSE}
64 {$IFDEF MSWINODWS}
65 LIBHDATE_LIBRARY_NAME = 'hdate.dll';
66 {$ELSE}
67 {$FATAL Unsupported environment}
68 {$ENDIF}
69 {$ENDIF}
70
71 (** @def HDATE_DIASPORA_FLAG
72 @brief use diaspora dates and holydays flag
73 *)
74 HDATE_DIASPORA_FLAG = -1;
75
76 (** @def HDATE_ISRAEL_FLAG
77 @brief use israel dates and holydays flag
78 *)
79 HDATE_ISRAEL_FLAG = 0;
80
81 (** @def HDATE_SHORT_FLAG
82 @brief use short strings flag
83 *)
84 HDATE_SHORT_FLAG = -1;
85
86 (** @def HDATE_LONG_FLAG
87 @brief use long strings flag
88 *)
89 HDATE_LONG_FLAG = 0;
90
91
92 { Base structore for hebrew dates }
93
94 Type
95 // A pointer to the Thdate_struct record
96 Phdate_struct = ^Thdate_struct;
97 Thdate_struct = Record
98 hd_day : cInt;
99 //The number of day in the hebrew month (1..31).
100 hd_mon : cInt;
101 //The number of the hebrew month 1..14 (1 - tishre, 13 - adar 1, 14 - adar 2).
102 hd_year : cInt;
103 //The number of the hebrew year.
104 gd_day : cInt;
105 //The number of the day in the month. (1..31)
106 gd_mon : cInt;
107 //The number of the month 1..12 (1 - jan).
108 gd_year : cInt;
109 //The number of the year.
110 hd_dw : cInt;
111 //The day of the week 1..7 (1 - sunday).
112 hd_size_of_year : cInt;
113 //The length of the year in days.
114 hd_new_year_dw : cInt;
115 //The week day of Hebrew new year.
116 hd_year_type : cInt;
117 //The number type of year.
118 hd_jd : cInt;
119 //The Julian day number
120 hd_days : cInt;
121 //The number of days passed since 1 tishrey
122 hd_weeks : cInt;
123 //The number of weeks passed since 1 tishrey
124 End;
125 (********************************************************************************)
126 (********************************************************************************)
127
128 Var
129 (**
130 @brief compute date structure from the Gregorian date
131
132 @param h pointer this hdate struct.
133 @param d Day of month 1..31
134 @param m Month 1..12
135 @param y Year in 4 digits e.g. 2001
136 @return pointer to this hdate struct
137 *)
138 hdate_set_gdate : Function (h : Phdate_struct; d, m, y : cInt) : Phdate_struct;
139
140
141 (**
142 @brief compute date structure from the Hebrew date
143
144 @param h pointer this hdate struct.
145 @param d Day of month 1..31
146 @param m Month 1..14 , (13 - Adar 1, 14 - Adar 2)
147 @param y Year in 4 digits e.g. 5731
148 @return pointer to this hdate struct
149 *)
150 hdate_set_hdate : Function (h : Phdate_struct; d, m, y : cInt) : Phdate_struct;
151
152
153 (**
154 @brief compute date structure from the Julian day
155
156 @param h pointer this hdate struct.
157 @param jd the julian day number.
158 @return pointer to this hdate struct
159 *)
160 hdate_set_jd : Function (h : Phdate_struct; jd : cInt) : Phdate_struct;
161
162 (*************************************************************)
163 (*************************************************************)
164
165
166 (**
167 @brief get formated hebrew date.
168
169 return the short ( e.g. "1 Tishrey" ) or
170 long (e.g. "Tuesday 18 Tishrey 5763 Hol hamoed Sukot" ) formated date.
171
172 @param h pointer this hdate struct.
173 @param diaspora if true give diaspora holydays.
174 @param s short flag.
175 @return a static string of foramted date
176 *)
177 hdate_get_format_date : Function (h : Phdate_struct; diaspora, s : cInt) : PChar;
178
179
180 (**
181 @brief get the number of hebrew parasha.
182
183 @param h pointer this hdate struct.
184 @param diaspora if true give diaspora readings
185 @return the number of parasha 1. Bereshit etc..
186 (55 trow 61 are joined strings e.g. Vayakhel Pekudei)
187 *)
188 hdate_get_parasha : Function (h : Phdate_struct; diaspora : cInt) : cInt;
189
190
191 (**
192 @brief get the number of hebrew holyday.
193
194 @param h pointer this hdate struct.
195 @param diaspora if true give diaspora holydays
196 @return the number of holyday.
197 *)
198 hdate_get_holyday : Function (h : Phdate_struct; diaspora : cInt) : cInt;
199
200 (*************************************************************)
201 (*************************************************************)
202
203
204 (**
205 @brief convert an integer to hebrew string.
206
207 @param n The int to convert
208 @return a static string of the hebrew number UTF-8 (logical)
209 @attention ( 0 < n < 10000)
210 *)
211 hdate_get_int_string : Function (n : cInt) : PChar;
212
213
214
215 (**
216 @brief get name of week day.
217
218 @param day The number of the day 1..7 (1 - sun).
219 @param s short flag
220 true - returns a short string: sun, false returns: sunday.
221 @return a static string of the day of the week
222 *)
223 hdate_get_day_string : Function (day : cInt; s : cInt) : PChar;
224
225
226
227 (**
228 @brief name of month.
229
230 @param month the number of the month 1..12 (1 - jan).
231 @param s short flag.
232 @return a static string of month name
233 *)
234 hdate_get_month_string : Function (month : cInt; s : cInt) : PChar;
235
236
237
238 (**
239 @brief name of hebrew month.
240
241 @param month the number of the month 1..14
242 (1 - tishre, 13 - adar 1, 14 - adar 2).
243 @param s short flag.
244 @return a static string of month name
245 *)
246 hdate_get_hebrew_month_string : Function (month : cInt; s : cInt) : PChar;
247
248
249
250 (**
251 @brief name of hebrew holyday.
252
253 @param holyday the holyday number.
254 @param s short flag.
255 @return a static string of holyday name
256 *)
257 hdate_get_holyday_string : Function (holyday, s : cInt) : PChar;
258
259
260
261 (**
262 @brief name of parasha
263
264 @param parasha the number of parasha 1-Bereshit
265 (55 trow 61 are joined strings e.g. Vayakhel Pekudei)
266 @param s short flag.
267 @return a static string of parasha name
268 *)
269 hdate_get_parasha_string : Function (parasha, s : cInt) : PChar;
270
271
272 (*************************************************************)
273 (*************************************************************)
274
275
276 (**
277 @brief get the hebrew holyday type.
278
279 @param holyday the holyday number.
280 @return the number of holyday type.
281 *)
282 hdate_get_holyday_type : Function (holyday : cInt) : cInt;
283
284
285
286 (**
287 @brief size of hebrew year in days.
288
289 @param hebrew_year the hebrew year.
290 @return size of Hebrew year
291 *)
292 hdate_get_size_of_hebrew_year : Function (hebrew_year : cInt) : cInt;
293
294
295 (*************************************************************)
296 (*************************************************************)
297
298
299 (**
300 @brief Days since Tishrey 3744
301
302 @author Amos Shapir 1984 (rev. 1985, 1992) Yaacov Zamir 2003-2005
303
304 @param hebrew_year The Hebrew year
305 @return Number of days since 3,1,3744
306 *)
307 hdate_days_from_3744 : Function (hebrew_year : cInt) : cInt;
308
309
310
311 (**
312 @brief Return Hebrew year type based on size and first week day of year.
313
314 @param size_of_year Length of year in days
315 @param new_year_dw First week day of year
316 @return the number for year type (1..14)
317 *)
318 hdate_get_year_type : Function (size_of_year, new_year_dw : cInt) : cInt;
319
320
321
322 (**
323 @brief Compute Julian day from Gregorian date
324
325 @author Yaacov Zamir (algorithm from Henry F. Fliegel and Thomas C. Van Flandern ,1968)
326
327 @param day Day of month 1..31
328 @param month Month 1..12
329 @param year Year in 4 digits e.g. 2001
330 @return the julian day number
331 *)
332 hdate_gdate_to_jd : Function (day, month, year : cInt) : cInt;
333
334
335
336 (**
337 @brief Compute Julian day from Hebrew day, month and year
338
339 @author Amos Shapir 1984 (rev. 1985, 1992) Yaacov Zamir 2003-2005
340
341 @param day Day of month 1..31
342 @param month Month 1..14 (13 - Adar 1, 14 - Adar 2)
343 @param year Hebrew year in 4 digits e.g. 5753
344 @param jd_tishrey1 return the julian number of 1 Tishrey this year
345 @param jd_tishrey1_next_year return the julian number of 1 Tishrey next year
346 @return the julian day number
347 *)
348 hdate_hdate_to_jd : Function (day, month, year : cInt; jd_tishrey1, jd_tishrey1_next_year : pcInt)
349 : cInt;
350
351
352
353 (**
354 @brief Converting from the Julian day to the Gregorian date
355
356 @author Yaacov Zamir (Algorithm, Henry F. Fliegel and Thomas C. Van Flandern ,1968)
357
358 @param jd Julian day
359 @param day return Day of month 1..31
360 @param month return Month 1..12
361 @param year return Year in 4 digits e.g. 2001
362 *)
363 hdate_jd_to_gdate : Procedure (jd : cInt; day, month, year : pcInt);
364
365
366
367 (**
368 @brief Converting from the Julian day to the Hebrew day
369
370 @author Yaacov Zamir 2005
371
372 @param jd Julian day
373 @param day return Day of month 1..31
374 @param month return Month 1..14 (13 - Adar 1, 14 - Adar 2)
375 @param year return Year in 4 digits e.g. 2001
376 @param jd_tishrey1 return the julian number of 1 Tishrey this year
377 @param jd_tishrey1_next_year return the julian number of 1 Tishrey next year
378 *)
379 hdate_jd_to_hdate : Procedure (jd : cInt; day, month, year, jd_tishrey1, jd_tishrey1_next_year :
380 pcInt);
381
382
383 (*************************************************************)
384 (*************************************************************)
385
386
387 (**
388 @brief days from 1 january
389
390 @param day this day of month
391 @param month this month
392 @param year this year
393 @return the days from 1 jan
394 *)
395 hdate_get_day_of_year : Function (day, month, year : cInt) : cInt;
396
397
398
399 (**
400 @brief utc sunrise/set time for a gregorian date
401
402 @param day this day of month
403 @param month this month
404 @param year this year
405 @param longitude longitude to use in calculations
406 degrees, negative values are east
407 @param latitude latitude to use in calculations
408 degrees, negative values are south
409 @param sunrise return the utc sunrise in minutes after midnight (00:00)
410 @param sunset return the utc sunset in minutes after midnight (00:00)
411 *)
412 hdate_get_utc_sun_time : Procedure (day, month, year : cInt; latitude, longitude : cDouble;
413 sunrise, sunset : pcInt);
414
415
416 (*************************************************************)
417 (*************************************************************)
418
419
420 (**
421 @brief get the Gregorian day of the month
422
423 @param h pointer this hdate struct.
424 @return the Gregorian day of the month, 1..31.
425 *)
426 hdate_get_gday : Function (h : Phdate_struct) : cInt;
427
428
429
430 (**
431 @brief get the Gregorian month
432
433 @param h pointer this hdate struct.
434 @return the Gregorian month, jan = 1.
435 *)
436 hdate_get_gmonth : Function (h : Phdate_struct) : cInt;
437
438
439
440 (**
441 @brief get the Gregorian year
442
443 @param h pointer this hdate struct.
444 @return the Gregorian year.
445 *)
446 hdate_get_gyear : Function (h : Phdate_struct) : cInt;
447
448
449
450 (**
451 @brief get the Hebrew day of the month
452
453 @param h pointer this hdate struct.
454 @return the Hebrew day of the month, 1..30.
455 *)
456 hdate_get_hday : Function (h : Phdate_struct) : cInt;
457
458
459
460 (**
461 @brief get the Hebrew month
462
463 @param h pointer this hdate struct.
464 @return the Hebrew month, Tishery = 1 .. Adar I =13, Adar II = 14.
465 *)
466 hdate_get_hmonth : Function (h : Phdate_struct) : cInt;
467
468
469 (**
470 @brief get the Hebrew year
471
472 @param h pointer this hdate struct.
473 @return the Hebrew year.
474 *)
475 hdate_get_hyear : Function (h : Phdate_struct) : cInt;
476
477
478
479 (**
480 @brief get the day of the week
481
482 @param h pointer this hdate struct.
483 @return the the day of the week.
484 *)
485 hdate_get_day_of_the_week : Function (h : Phdate_struct) : cInt;
486
487
488
489 (**
490 @brief get the size of the hebrew year
491
492 @param h pointer this hdate struct.
493 @return the the size of the hebrew year.
494 *)
495 hdate_get_size_of_year : Function (h : Phdate_struct) : cInt;
496
497
498
499 (**
500 @brief get the new year day of the week
501
502 @param h pointer this hdate struct.
503 @return the the new year day of the week.
504 *)
505 hdate_get_new_year_day_of_the_week : Function (h : Phdate_struct) : cInt;
506
507
508
509 (**
510 @brief get the Julian day number
511
512 @param h pointer this hdate struct.
513 @return the Julian day number.
514 *)
515 hdate_get_julian : Function (h : Phdate_struct) : cInt;
516
517
518
519 (**
520 @brief get the number of days passed since 1 tishrey
521
522 @param h pointer this hdate struct.
523 @return the number of days passed since 1 tishrey.
524 *)
525 hdate_get_days : Function (h : Phdate_struct) : cInt;
526
527
528
529 (**
530 @brief get the number of weeks passed since 1 tishrey
531
532 @param h pointer this hdate struct.
533 @return the number of weeks passed since 1 tishrey.
534 *)
535 hdate_get_weeks : Function (h : Phdate_struct) : cInt;
536
537
538 (*************************************************************)
539 (*************************************************************)
540
541
542 (**
543 @brief creat a new hdate struct object, must be deleted using delete_hdate.
544
545 @return a new hdate object
546 *)
547 new_hdate : Function : Phdate_struct;
548
549
550 (**
551 @brief delete an hdate struct object.
552
553 @param h pointer this hdate struct.
554 *)
555 delete_hdate : Function (h : Phdate_struct) : Phdate_struct;
556
557
558 (*************************************************************)
559 (*************************************************************)
560
561
562 (**
563 @brief Return a static string, with the package name and version
564
565 @return a a static string, with the package name and version
566 *)
567 hdate_get_version_string : Function : PChar;
568
569
570 (**
571 @brief Return a static string, with the name of translator
572
573 @return a a static string, with the name of translator
574 *)
575 hdate_get_translator_string : Function : PChar;
576
577
578 (**
579 @brief utc sun times for altitude at a gregorian date
580
581 @param day this day of month
582 @param month this month
583 @param year this year
584 @param latitude latitude to use in calculations
585 @param longitude longitude to use in calculations
586 @param deg degrees of sun's altitude (0 - Zenith .. 90 - Horizon)
587 @param sunrise return the utc sunrise in minutes
588 @param sunset return the utc sunset in minutes
589 *)
590 hdate_get_utc_sun_time_deg : Procedure (day, month, year : cint;
591 latitude, longitude, deg : cdouble;
592 sunrise, sunset : pcint);
593
594
595 (**
596 @brief utc sunrise/set time for a gregorian date
597
598 @param day this day of month
599 @param month this month
600 @param year this year
601 @param longitude longitude to use in calculations
602 @param latitude latitude to use in calculations
603 @param sun_hour return the length of shaa zmanit in minutes
604 @param first_light return the utc alut ha-shachar in minutes
605 @param talit return the utc tphilin and talit in minutes
606 @param sunrise return the utc sunrise in minutes
607 @param midday return the utc midday in minutes
608 @param sunset return the utc sunset in minutes
609 @param first_stars return the utc tzeit hacochavim in minutes
610 @param three_stars return the utc shlosha cochavim in minutes
611 *)
612 hdate_get_utc_sun_time_full : Procedure (day, month, year : cint;
613 latitude, longitude : cdouble;
614 sun_hour, first_light, talit, sunrise, midday, sunset,
615 first_stars, three_stars : pcint);
616
617
618 Implementation
619 Uses dynlibs;
620
621 Var
622 Loaded : Boolean;
623 LibHandle : TLibHandle;
624
625 Procedure hdate_init;
626
627 { Internal function of hdate_init, that load the function and assign it to the right function/procedure}
628 Function AssignProc(Name : PChar; Fnc : Pointer) : boolean;
629 Var
630 address : pointer;
631 pfnc : ^pointer;
632 Begin
633 address := Nil;
634 address := GetProcedureAddress(LibHandle, Name);
635 pfnc := Fnc;
636 pfnc^ := address;
637 AssignProc := address <> Nil;
638 End;
639
640 Begin
641 If (Loaded) and (LibHandle <> NilHandle) Then
642 exit;
643
644 Loaded := False;
645 LibHandle := LoadLibrary(LIBHDATE_LIBRARY_NAME);
646 If LibHandle = NilHandle Then
647 exit;
648
649 If Not AssignProc('hdate_set_gdate', @hdate_set_gdate) Then
650 exit;
651 If Not AssignProc('hdate_set_hdate', @hdate_set_hdate) Then
652 exit;
653 If Not AssignProc('hdate_set_jd', @hdate_set_jd) Then
654 exit;
655 If Not AssignProc('hdate_get_format_date', @hdate_get_format_date) Then
656 exit;
657 If Not AssignProc('hdate_get_parasha', @hdate_get_parasha) Then
658 exit;
659 If Not AssignProc('hdate_get_holyday', @hdate_get_holyday) Then
660 exit;
661 If Not AssignProc('hdate_get_int_string', @hdate_get_int_string) Then
662 exit;
663 If Not AssignProc('hdate_get_day_string', @hdate_get_day_string) Then
664 exit;
665 If Not AssignProc('hdate_get_month_string', @hdate_get_month_string) Then
666 exit;
667 If Not AssignProc('hdate_get_hebrew_month_string', @hdate_get_hebrew_month_string) Then
668 exit;
669 If Not AssignProc('hdate_get_holyday_string', @hdate_get_holyday_string) Then
670 exit;
671 If Not AssignProc('hdate_get_parasha_string', @hdate_get_parasha_string) Then
672 exit;
673 If Not AssignProc('hdate_get_holyday_type', @hdate_get_holyday_type) Then
674 exit;
675 If Not AssignProc('hdate_get_size_of_hebrew_year', @hdate_get_size_of_hebrew_year) Then
676 exit;
677 If Not AssignProc('hdate_days_from_3744', @hdate_days_from_3744) Then
678 exit;
679 If Not AssignProc('hdate_get_year_type', @hdate_get_year_type) Then
680 exit;
681 If Not AssignProc('hdate_gdate_to_jd', @hdate_gdate_to_jd) Then
682 exit;
683 If Not AssignProc('hdate_hdate_to_jd', @hdate_hdate_to_jd) Then
684 exit;
685 If Not AssignProc('hdate_jd_to_gdate', @hdate_jd_to_gdate) Then
686 exit;
687 If Not AssignProc('hdate_jd_to_hdate', @hdate_jd_to_hdate) Then
688 exit;
689 If Not AssignProc('hdate_get_day_of_year', @hdate_get_day_of_year) Then
690 exit;
691 If Not AssignProc('hdate_get_utc_sun_time', @hdate_get_utc_sun_time) Then
692 exit;
693 If Not AssignProc('hdate_get_gday', @hdate_get_gday) Then
694 exit;
695 If Not AssignProc('hdate_get_gmonth', @hdate_get_gmonth) Then
696 exit;
697 If Not AssignProc('hdate_get_gyear', @hdate_get_gyear) Then
698 exit;
699 If Not AssignProc('hdate_get_hday', @hdate_get_hday) Then
700 exit;
701 If Not AssignProc('hdate_get_hmonth', @hdate_get_hmonth) Then
702 exit;
703 If Not AssignProc('hdate_get_hyear', @hdate_get_hyear) Then
704 exit;
705 If Not AssignProc('hdate_get_day_of_the_week', @hdate_get_day_of_the_week) Then
706 exit;
707 If Not AssignProc('hdate_get_size_of_year', @hdate_get_size_of_year) Then
708 exit;
709 If Not AssignProc('hdate_get_new_year_day_of_the_week', @hdate_get_new_year_day_of_the_week) Then
710 exit;
711 If Not AssignProc('hdate_get_julian', @hdate_get_julian) Then
712 exit;
713 If Not AssignProc('hdate_get_days', @hdate_get_days) Then
714 exit;
715 If Not AssignProc('hdate_get_weeks', @hdate_get_weeks) Then
716 exit;
717 If Not AssignProc('new_hdate', @new_hdate) Then
718 exit;
719 If Not AssignProc('delete_hdate', @delete_hdate) Then
720 exit;
721 If Not AssignProc('hdate_get_version_string', @hdate_get_version_string) Then
722 exit;
723 If Not AssignProc('hdate_get_translator_string', @hdate_get_translator_string) Then
724 exit;
725 If Not AssignProc('hdate_get_utc_sun_time_deg', @hdate_get_utc_sun_time_deg) Then
726 exit;
727 If Not AssignProc('hdate_get_utc_sun_time_full', @hdate_get_utc_sun_time_full) Then
728 exit;
729
730 Loaded := true;
731 End;
732
733 Procedure hdate_done;
734 Begin
735 If LibHandle <> NilHandle Then
736 UnloadLibrary(LibHandle);
737
738 LibHandle := NilHandle;
739 Loaded := false;
740 End;
741
742 Function IsLoaded : Boolean;
743 Begin
744 IsLoaded := Loaded;
745 End;
746
747 initialization
748 Loaded := false;
749 {$IFDEF AUTO_LOAD}
750 hdate_init;
751 {$ENDIF}
752 finalization
753 {$IFDEF AUTO_LOAD}
754 hdate_done;
755 {$ENDIF}
756 End.
757
119119 PA_VERSION = @PA_VERSION@
120120 PE_CFLAGS = @PE_CFLAGS@
121121 PE_MODULES_PATH = @PE_MODULES_PATH@
122 PH_CONFIG_PATH = @PH_CONFIG_PATH@
123 PH_MODULES_PATH = @PH_MODULES_PATH@
122124 PKG_CONFIG = @PKG_CONFIG@
123125 POSUB = @POSUB@
124126 PY_CFLAGS = @PY_CFLAGS@
125127 PY_MODULES_PATH = @PY_MODULES_PATH@
126128 PY_VERSION = @PY_VERSION@
127129 RANLIB = @RANLIB@
130 RU_CFLAGS = @RU_CFLAGS@
131 RU_MODULES_PATH = @RU_MODULES_PATH@
132 RU_VERSION = @RU_VERSION@
128133 SED = @SED@
129134 SET_MAKE = @SET_MAKE@
130135 SHELL = @SHELL@
138143 WITH_PASCAL_TRUE = @WITH_PASCAL_TRUE@
139144 WITH_PERL_FALSE = @WITH_PERL_FALSE@
140145 WITH_PERL_TRUE = @WITH_PERL_TRUE@
146 WITH_PHP_FALSE = @WITH_PHP_FALSE@
147 WITH_PHP_TRUE = @WITH_PHP_TRUE@
141148 WITH_PYTHON_FALSE = @WITH_PYTHON_FALSE@
142149 WITH_PYTHON_TRUE = @WITH_PYTHON_TRUE@
150 WITH_RUBY_FALSE = @WITH_RUBY_FALSE@
151 WITH_RUBY_TRUE = @WITH_RUBY_TRUE@
143152 XGETTEXT = @XGETTEXT@
144153 XGETTEXT_015 = @XGETTEXT_015@
145154 XGETTEXT_EXTRA_OPTIONS = @XGETTEXT_EXTRA_OPTIONS@
168177 exec_prefix = @exec_prefix@
169178 have_pascal = @have_pascal@
170179 have_perl = @have_perl@
180 have_php = @have_php@
181 have_php_config = @have_php_config@
171182 have_python = @have_python@
183 have_ruby = @have_ruby@
172184 have_swig = @have_swig@
173185 host = @host@
174186 host_alias = @host_alias@
0
1 EXTRA_DIST = hdate.i hdate.ini
2
3 if WITH_PHP
4
5 DEPS= $(top_builddir)/src/libhdate.la
6
7 CLEANFILES = *.o *.cpp *.h *.so *wrap*
8
9 all-am: hdate.so
10
11
12 hdate.so: hdate_wrap.cpp
13 g++ -I$(top_srcdir)/src `php-config --includes` -fpic -c hdate_wrap.cpp
14 gcc -shared ../../src/.libs/libhdate.so hdate_wrap.o -lstdc++ -o hdate.so
15
16 hdate_wrap.cpp: hdate.i
17 swig -php5 -c++ hdate.i
18
19 install-data-local: hdate.so hdate.ini
20 $(mkinstalldirs) $(DESTDIR)$(PH_MODULES_PATH)
21 $(INSTALL_DATA) hdate.so $(DESTDIR)$(PH_MODULES_PATH)/hdate.so
22
23 $(mkinstalldirs) $(DESTDIR)$(PH_CONFIG_PATH)
24 $(INSTALL_DATA) hdate.ini $(DESTDIR)$(PH_CONFIG_PATH)/hdate.ini
25 endif
0 # Makefile.in generated by automake 1.9.6 from Makefile.am.
1 # @configure_input@
2
3 # Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
4 # 2003, 2004, 2005 Free Software Foundation, Inc.
5 # This Makefile.in is free software; the Free Software Foundation
6 # gives unlimited permission to copy and/or distribute it,
7 # with or without modifications, as long as this notice is preserved.
8
9 # This program is distributed in the hope that it will be useful,
10 # but WITHOUT ANY WARRANTY, to the extent permitted by law; without
11 # even the implied warranty of MERCHANTABILITY or FITNESS FOR A
12 # PARTICULAR PURPOSE.
13
14 @SET_MAKE@
15 srcdir = @srcdir@
16 top_srcdir = @top_srcdir@
17 VPATH = @srcdir@
18 pkgdatadir = $(datadir)/@PACKAGE@
19 pkglibdir = $(libdir)/@PACKAGE@
20 pkgincludedir = $(includedir)/@PACKAGE@
21 top_builddir = ../..
22 am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
23 INSTALL = @INSTALL@
24 install_sh_DATA = $(install_sh) -c -m 644
25 install_sh_PROGRAM = $(install_sh) -c
26 install_sh_SCRIPT = $(install_sh) -c
27 INSTALL_HEADER = $(INSTALL_DATA)
28 transform = $(program_transform_name)
29 NORMAL_INSTALL = :
30 PRE_INSTALL = :
31 POST_INSTALL = :
32 NORMAL_UNINSTALL = :
33 PRE_UNINSTALL = :
34 POST_UNINSTALL = :
35 build_triplet = @build@
36 host_triplet = @host@
37 subdir = bindings/php
38 DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in
39 ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
40 am__aclocal_m4_deps = $(top_srcdir)/m4/gettext.m4 \
41 $(top_srcdir)/m4/iconv.m4 $(top_srcdir)/m4/intlmacosx.m4 \
42 $(top_srcdir)/m4/lib-ld.m4 $(top_srcdir)/m4/lib-link.m4 \
43 $(top_srcdir)/m4/lib-prefix.m4 $(top_srcdir)/m4/nls.m4 \
44 $(top_srcdir)/m4/po.m4 $(top_srcdir)/m4/progtest.m4 \
45 $(top_srcdir)/configure.in
46 am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
47 $(ACLOCAL_M4)
48 mkinstalldirs = $(install_sh) -d
49 CONFIG_CLEAN_FILES =
50 SOURCES =
51 DIST_SOURCES =
52 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
53 ACLOCAL = @ACLOCAL@
54 AMDEP_FALSE = @AMDEP_FALSE@
55 AMDEP_TRUE = @AMDEP_TRUE@
56 AMTAR = @AMTAR@
57 AR = @AR@
58 AUTOCONF = @AUTOCONF@
59 AUTOHEADER = @AUTOHEADER@
60 AUTOMAKE = @AUTOMAKE@
61 AWK = @AWK@
62 CC = @CC@
63 CCDEPMODE = @CCDEPMODE@
64 CFLAGS = @CFLAGS@
65 CPP = @CPP@
66 CPPFLAGS = @CPPFLAGS@
67 CXX = @CXX@
68 CXXCPP = @CXXCPP@
69 CXXDEPMODE = @CXXDEPMODE@
70 CXXFLAGS = @CXXFLAGS@
71 CYGPATH_W = @CYGPATH_W@
72 DATADIRNAME = @DATADIRNAME@
73 DEFS = @DEFS@
74 DEPDIR = @DEPDIR@
75 ECHO = @ECHO@
76 ECHO_C = @ECHO_C@
77 ECHO_N = @ECHO_N@
78 ECHO_T = @ECHO_T@
79 EGREP = @EGREP@
80 EXEEXT = @EXEEXT@
81 F77 = @F77@
82 FFLAGS = @FFLAGS@
83 GETTEXT_MACRO_VERSION = @GETTEXT_MACRO_VERSION@
84 GMSGFMT = @GMSGFMT@
85 GMSGFMT_015 = @GMSGFMT_015@
86 GREP = @GREP@
87 INSTALL_DATA = @INSTALL_DATA@
88 INSTALL_PROGRAM = @INSTALL_PROGRAM@
89 INSTALL_SCRIPT = @INSTALL_SCRIPT@
90 INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
91 INTLLIBS = @INTLLIBS@
92 INTL_MACOSX_LIBS = @INTL_MACOSX_LIBS@
93 LDFLAGS = @LDFLAGS@
94 LIBICONV = @LIBICONV@
95 LIBINTL = @LIBINTL@
96 LIBOBJS = @LIBOBJS@
97 LIBS = @LIBS@
98 LIBTOOL = @LIBTOOL@
99 LN_S = @LN_S@
100 LTLIBICONV = @LTLIBICONV@
101 LTLIBINTL = @LTLIBINTL@
102 LTLIBOBJS = @LTLIBOBJS@
103 MAINT = @MAINT@
104 MAINTAINER_MODE_FALSE = @MAINTAINER_MODE_FALSE@
105 MAINTAINER_MODE_TRUE = @MAINTAINER_MODE_TRUE@
106 MAKEINFO = @MAKEINFO@
107 MSGFMT = @MSGFMT@
108 MSGFMT_015 = @MSGFMT_015@
109 MSGMERGE = @MSGMERGE@
110 OBJEXT = @OBJEXT@
111 PACKAGE = @PACKAGE@
112 PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
113 PACKAGE_NAME = @PACKAGE_NAME@
114 PACKAGE_STRING = @PACKAGE_STRING@
115 PACKAGE_TARNAME = @PACKAGE_TARNAME@
116 PACKAGE_VERSION = @PACKAGE_VERSION@
117 PATH_SEPARATOR = @PATH_SEPARATOR@
118 PA_MODULES_PATH = @PA_MODULES_PATH@
119 PA_VERSION = @PA_VERSION@
120 PE_CFLAGS = @PE_CFLAGS@
121 PE_MODULES_PATH = @PE_MODULES_PATH@
122 PH_CONFIG_PATH = @PH_CONFIG_PATH@
123 PH_MODULES_PATH = @PH_MODULES_PATH@
124 PKG_CONFIG = @PKG_CONFIG@
125 POSUB = @POSUB@
126 PY_CFLAGS = @PY_CFLAGS@
127 PY_MODULES_PATH = @PY_MODULES_PATH@
128 PY_VERSION = @PY_VERSION@
129 RANLIB = @RANLIB@
130 RU_CFLAGS = @RU_CFLAGS@
131 RU_MODULES_PATH = @RU_MODULES_PATH@
132 RU_VERSION = @RU_VERSION@
133 SED = @SED@
134 SET_MAKE = @SET_MAKE@
135 SHELL = @SHELL@
136 STRIP = @STRIP@
137 USE_NLS = @USE_NLS@
138 VERSION = @VERSION@
139 VERSION_INFO = @VERSION_INFO@
140 WITH_HCAL_FALSE = @WITH_HCAL_FALSE@
141 WITH_HCAL_TRUE = @WITH_HCAL_TRUE@
142 WITH_PASCAL_FALSE = @WITH_PASCAL_FALSE@
143 WITH_PASCAL_TRUE = @WITH_PASCAL_TRUE@
144 WITH_PERL_FALSE = @WITH_PERL_FALSE@
145 WITH_PERL_TRUE = @WITH_PERL_TRUE@
146 WITH_PHP_FALSE = @WITH_PHP_FALSE@
147 WITH_PHP_TRUE = @WITH_PHP_TRUE@
148 WITH_PYTHON_FALSE = @WITH_PYTHON_FALSE@
149 WITH_PYTHON_TRUE = @WITH_PYTHON_TRUE@
150 WITH_RUBY_FALSE = @WITH_RUBY_FALSE@
151 WITH_RUBY_TRUE = @WITH_RUBY_TRUE@
152 XGETTEXT = @XGETTEXT@
153 XGETTEXT_015 = @XGETTEXT_015@
154 XGETTEXT_EXTRA_OPTIONS = @XGETTEXT_EXTRA_OPTIONS@
155 ac_ct_CC = @ac_ct_CC@
156 ac_ct_CXX = @ac_ct_CXX@
157 ac_ct_F77 = @ac_ct_F77@
158 am__fastdepCC_FALSE = @am__fastdepCC_FALSE@
159 am__fastdepCC_TRUE = @am__fastdepCC_TRUE@
160 am__fastdepCXX_FALSE = @am__fastdepCXX_FALSE@
161 am__fastdepCXX_TRUE = @am__fastdepCXX_TRUE@
162 am__include = @am__include@
163 am__leading_dot = @am__leading_dot@
164 am__quote = @am__quote@
165 am__tar = @am__tar@
166 am__untar = @am__untar@
167 bindir = @bindir@
168 build = @build@
169 build_alias = @build_alias@
170 build_cpu = @build_cpu@
171 build_os = @build_os@
172 build_vendor = @build_vendor@
173 datadir = @datadir@
174 datarootdir = @datarootdir@
175 docdir = @docdir@
176 dvidir = @dvidir@
177 exec_prefix = @exec_prefix@
178 have_pascal = @have_pascal@
179 have_perl = @have_perl@
180 have_php = @have_php@
181 have_php_config = @have_php_config@
182 have_python = @have_python@
183 have_ruby = @have_ruby@
184 have_swig = @have_swig@
185 host = @host@
186 host_alias = @host_alias@
187 host_cpu = @host_cpu@
188 host_os = @host_os@
189 host_vendor = @host_vendor@
190 htmldir = @htmldir@
191 includedir = @includedir@
192 infodir = @infodir@
193 install_sh = @install_sh@
194 libdir = @libdir@
195 libexecdir = @libexecdir@
196 localedir = @localedir@
197 localstatedir = @localstatedir@
198 mandir = @mandir@
199 mkdir_p = @mkdir_p@
200 oldincludedir = @oldincludedir@
201 pdfdir = @pdfdir@
202 prefix = @prefix@
203 program_transform_name = @program_transform_name@
204 psdir = @psdir@
205 sbindir = @sbindir@
206 sharedstatedir = @sharedstatedir@
207 sysconfdir = @sysconfdir@
208 target_alias = @target_alias@
209 EXTRA_DIST = hdate.i hdate.ini
210 @WITH_PHP_TRUE@DEPS = $(top_builddir)/src/libhdate.la
211 @WITH_PHP_TRUE@CLEANFILES = *.o *.cpp *.h *.so *wrap*
212 all: all-am
213
214 .SUFFIXES:
215 $(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(am__configure_deps)
216 @for dep in $?; do \
217 case '$(am__configure_deps)' in \
218 *$$dep*) \
219 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh \
220 && exit 0; \
221 exit 1;; \
222 esac; \
223 done; \
224 echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu bindings/php/Makefile'; \
225 cd $(top_srcdir) && \
226 $(AUTOMAKE) --gnu bindings/php/Makefile
227 .PRECIOUS: Makefile
228 Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
229 @case '$?' in \
230 *config.status*) \
231 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \
232 *) \
233 echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \
234 cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \
235 esac;
236
237 $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
238 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
239
240 $(top_srcdir)/configure: @MAINTAINER_MODE_TRUE@ $(am__configure_deps)
241 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
242 $(ACLOCAL_M4): @MAINTAINER_MODE_TRUE@ $(am__aclocal_m4_deps)
243 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
244
245 mostlyclean-libtool:
246 -rm -f *.lo
247
248 clean-libtool:
249 -rm -rf .libs _libs
250
251 distclean-libtool:
252 -rm -f libtool
253 uninstall-info-am:
254 tags: TAGS
255 TAGS:
256
257 ctags: CTAGS
258 CTAGS:
259
260
261 distdir: $(DISTFILES)
262 @srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; \
263 topsrcdirstrip=`echo "$(top_srcdir)" | sed 's|.|.|g'`; \
264 list='$(DISTFILES)'; for file in $$list; do \
265 case $$file in \
266 $(srcdir)/*) file=`echo "$$file" | sed "s|^$$srcdirstrip/||"`;; \
267 $(top_srcdir)/*) file=`echo "$$file" | sed "s|^$$topsrcdirstrip/|$(top_builddir)/|"`;; \
268 esac; \
269 if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
270 dir=`echo "$$file" | sed -e 's,/[^/]*$$,,'`; \
271 if test "$$dir" != "$$file" && test "$$dir" != "."; then \
272 dir="/$$dir"; \
273 $(mkdir_p) "$(distdir)$$dir"; \
274 else \
275 dir=''; \
276 fi; \
277 if test -d $$d/$$file; then \
278 if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
279 cp -pR $(srcdir)/$$file $(distdir)$$dir || exit 1; \
280 fi; \
281 cp -pR $$d/$$file $(distdir)$$dir || exit 1; \
282 else \
283 test -f $(distdir)/$$file \
284 || cp -p $$d/$$file $(distdir)/$$file \
285 || exit 1; \
286 fi; \
287 done
288 check-am: all-am
289 check: check-am
290 all-am: Makefile
291 installdirs:
292 install: install-am
293 install-exec: install-exec-am
294 install-data: install-data-am
295 uninstall: uninstall-am
296
297 install-am: all-am
298 @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
299
300 installcheck: installcheck-am
301 install-strip:
302 $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
303 install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
304 `test -z '$(STRIP)' || \
305 echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install
306 mostlyclean-generic:
307
308 clean-generic:
309 -test -z "$(CLEANFILES)" || rm -f $(CLEANFILES)
310
311 distclean-generic:
312 -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
313
314 maintainer-clean-generic:
315 @echo "This command is intended for maintainers to use"
316 @echo "it deletes files that may require special tools to rebuild."
317 @WITH_PHP_FALSE@install-data-local:
318 clean: clean-am
319
320 clean-am: clean-generic clean-libtool mostlyclean-am
321
322 distclean: distclean-am
323 -rm -f Makefile
324 distclean-am: clean-am distclean-generic distclean-libtool
325
326 dvi: dvi-am
327
328 dvi-am:
329
330 html: html-am
331
332 info: info-am
333
334 info-am:
335
336 install-data-am: install-data-local
337
338 install-exec-am:
339
340 install-info: install-info-am
341
342 install-man:
343
344 installcheck-am:
345
346 maintainer-clean: maintainer-clean-am
347 -rm -f Makefile
348 maintainer-clean-am: distclean-am maintainer-clean-generic
349
350 mostlyclean: mostlyclean-am
351
352 mostlyclean-am: mostlyclean-generic mostlyclean-libtool
353
354 pdf: pdf-am
355
356 pdf-am:
357
358 ps: ps-am
359
360 ps-am:
361
362 uninstall-am: uninstall-info-am
363
364 .PHONY: all all-am check check-am clean clean-generic clean-libtool \
365 distclean distclean-generic distclean-libtool distdir dvi \
366 dvi-am html html-am info info-am install install-am \
367 install-data install-data-am install-data-local install-exec \
368 install-exec-am install-info install-info-am install-man \
369 install-strip installcheck installcheck-am installdirs \
370 maintainer-clean maintainer-clean-generic mostlyclean \
371 mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \
372 uninstall uninstall-am uninstall-info-am
373
374
375 @WITH_PHP_TRUE@all-am: hdate.so
376
377 @WITH_PHP_TRUE@hdate.so: hdate_wrap.cpp
378 @WITH_PHP_TRUE@ g++ -I$(top_srcdir)/src `php-config --includes` -fpic -c hdate_wrap.cpp
379 @WITH_PHP_TRUE@ gcc -shared ../../src/.libs/libhdate.so hdate_wrap.o -lstdc++ -o hdate.so
380
381 @WITH_PHP_TRUE@hdate_wrap.cpp: hdate.i
382 @WITH_PHP_TRUE@ swig -php5 -c++ hdate.i
383
384 @WITH_PHP_TRUE@install-data-local: hdate.so hdate.ini
385 @WITH_PHP_TRUE@ $(mkinstalldirs) $(DESTDIR)$(PH_MODULES_PATH)
386 @WITH_PHP_TRUE@ $(INSTALL_DATA) hdate.so $(DESTDIR)$(PH_MODULES_PATH)/hdate.so
387
388 @WITH_PHP_TRUE@ $(mkinstalldirs) $(DESTDIR)$(PH_CONFIG_PATH)
389 @WITH_PHP_TRUE@ $(INSTALL_DATA) hdate.ini $(DESTDIR)$(PH_CONFIG_PATH)/hdate.ini
390 # Tell versions [3.59,3.63) of GNU make to not export all variables.
391 # Otherwise a system limit (for SysV at least) may be exceeded.
392 .NOEXPORT:
0 // file : hdate.i
1 %module hdate
2 %{
3 #include "../../src/hdatepp.h"
4 %}
5
6 %include ../../src/hdatepp.h
7
8
0 # configuration for php hdate module
1 extension=hdate.so
119119 PA_VERSION = @PA_VERSION@
120120 PE_CFLAGS = @PE_CFLAGS@
121121 PE_MODULES_PATH = @PE_MODULES_PATH@
122 PH_CONFIG_PATH = @PH_CONFIG_PATH@
123 PH_MODULES_PATH = @PH_MODULES_PATH@
122124 PKG_CONFIG = @PKG_CONFIG@
123125 POSUB = @POSUB@
124126 PY_CFLAGS = @PY_CFLAGS@
125127 PY_MODULES_PATH = @PY_MODULES_PATH@
126128 PY_VERSION = @PY_VERSION@
127129 RANLIB = @RANLIB@
130 RU_CFLAGS = @RU_CFLAGS@
131 RU_MODULES_PATH = @RU_MODULES_PATH@
132 RU_VERSION = @RU_VERSION@
128133 SED = @SED@
129134 SET_MAKE = @SET_MAKE@
130135 SHELL = @SHELL@
138143 WITH_PASCAL_TRUE = @WITH_PASCAL_TRUE@
139144 WITH_PERL_FALSE = @WITH_PERL_FALSE@
140145 WITH_PERL_TRUE = @WITH_PERL_TRUE@
146 WITH_PHP_FALSE = @WITH_PHP_FALSE@
147 WITH_PHP_TRUE = @WITH_PHP_TRUE@
141148 WITH_PYTHON_FALSE = @WITH_PYTHON_FALSE@
142149 WITH_PYTHON_TRUE = @WITH_PYTHON_TRUE@
150 WITH_RUBY_FALSE = @WITH_RUBY_FALSE@
151 WITH_RUBY_TRUE = @WITH_RUBY_TRUE@
143152 XGETTEXT = @XGETTEXT@
144153 XGETTEXT_015 = @XGETTEXT_015@
145154 XGETTEXT_EXTRA_OPTIONS = @XGETTEXT_EXTRA_OPTIONS@
168177 exec_prefix = @exec_prefix@
169178 have_pascal = @have_pascal@
170179 have_perl = @have_perl@
180 have_php = @have_php@
181 have_php_config = @have_php_config@
171182 have_python = @have_python@
183 have_ruby = @have_ruby@
172184 have_swig = @have_swig@
173185 host = @host@
174186 host_alias = @host_alias@
0
1 EXTRA_DIST = hdate.i
2
3 if WITH_RUBY
4
5 DEPS= $(top_builddir)/src/libhdate.la
6
7 CLEANFILES = *.o *.cxx *.so *wrap*
8
9 all-am: hdate.so
10
11
12 hdate.so: hdate_wrap.cxx
13 g++ -fpic -fno-strict-aliasing -g -O2 -c hdate_wrap.cxx $(RU_CFLAGS) -I$(top_srcdir)/src
14 gcc -shared ../../src/.libs/libhdate.so hdate_wrap.o -rdynamic -Wl,-export-dynamic -lruby$(RU_VERSION) -lpthread -ldl -lcrypt -lm -lc -lstdc++ -o hdate.so
15
16 hdate_wrap.cxx: hdate.i
17 swig -c++ -ruby hdate.i
18
19 install-data-local: hdate.so
20 $(mkinstalldirs) $(DESTDIR)$(RU_MODULES_PATH)
21 $(INSTALL_DATA) hdate.so $(DESTDIR)$(RU_MODULES_PATH)/hdate.so
22
23 endif
0 # Makefile.in generated by automake 1.9.6 from Makefile.am.
1 # @configure_input@
2
3 # Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
4 # 2003, 2004, 2005 Free Software Foundation, Inc.
5 # This Makefile.in is free software; the Free Software Foundation
6 # gives unlimited permission to copy and/or distribute it,
7 # with or without modifications, as long as this notice is preserved.
8
9 # This program is distributed in the hope that it will be useful,
10 # but WITHOUT ANY WARRANTY, to the extent permitted by law; without
11 # even the implied warranty of MERCHANTABILITY or FITNESS FOR A
12 # PARTICULAR PURPOSE.
13
14 @SET_MAKE@
15 srcdir = @srcdir@
16 top_srcdir = @top_srcdir@
17 VPATH = @srcdir@
18 pkgdatadir = $(datadir)/@PACKAGE@
19 pkglibdir = $(libdir)/@PACKAGE@
20 pkgincludedir = $(includedir)/@PACKAGE@
21 top_builddir = ../..
22 am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
23 INSTALL = @INSTALL@
24 install_sh_DATA = $(install_sh) -c -m 644
25 install_sh_PROGRAM = $(install_sh) -c
26 install_sh_SCRIPT = $(install_sh) -c
27 INSTALL_HEADER = $(INSTALL_DATA)
28 transform = $(program_transform_name)
29 NORMAL_INSTALL = :
30 PRE_INSTALL = :
31 POST_INSTALL = :
32 NORMAL_UNINSTALL = :
33 PRE_UNINSTALL = :
34 POST_UNINSTALL = :
35 build_triplet = @build@
36 host_triplet = @host@
37 subdir = bindings/ruby
38 DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in
39 ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
40 am__aclocal_m4_deps = $(top_srcdir)/m4/gettext.m4 \
41 $(top_srcdir)/m4/iconv.m4 $(top_srcdir)/m4/intlmacosx.m4 \
42 $(top_srcdir)/m4/lib-ld.m4 $(top_srcdir)/m4/lib-link.m4 \
43 $(top_srcdir)/m4/lib-prefix.m4 $(top_srcdir)/m4/nls.m4 \
44 $(top_srcdir)/m4/po.m4 $(top_srcdir)/m4/progtest.m4 \
45 $(top_srcdir)/configure.in
46 am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
47 $(ACLOCAL_M4)
48 mkinstalldirs = $(install_sh) -d
49 CONFIG_CLEAN_FILES =
50 SOURCES =
51 DIST_SOURCES =
52 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
53 ACLOCAL = @ACLOCAL@
54 AMDEP_FALSE = @AMDEP_FALSE@
55 AMDEP_TRUE = @AMDEP_TRUE@
56 AMTAR = @AMTAR@
57 AR = @AR@
58 AUTOCONF = @AUTOCONF@
59 AUTOHEADER = @AUTOHEADER@
60 AUTOMAKE = @AUTOMAKE@
61 AWK = @AWK@
62 CC = @CC@
63 CCDEPMODE = @CCDEPMODE@
64 CFLAGS = @CFLAGS@
65 CPP = @CPP@
66 CPPFLAGS = @CPPFLAGS@
67 CXX = @CXX@
68 CXXCPP = @CXXCPP@
69 CXXDEPMODE = @CXXDEPMODE@
70 CXXFLAGS = @CXXFLAGS@
71 CYGPATH_W = @CYGPATH_W@
72 DATADIRNAME = @DATADIRNAME@
73 DEFS = @DEFS@
74 DEPDIR = @DEPDIR@
75 ECHO = @ECHO@
76 ECHO_C = @ECHO_C@
77 ECHO_N = @ECHO_N@
78 ECHO_T = @ECHO_T@
79 EGREP = @EGREP@
80 EXEEXT = @EXEEXT@
81 F77 = @F77@
82 FFLAGS = @FFLAGS@
83 GETTEXT_MACRO_VERSION = @GETTEXT_MACRO_VERSION@
84 GMSGFMT = @GMSGFMT@
85 GMSGFMT_015 = @GMSGFMT_015@
86 GREP = @GREP@
87 INSTALL_DATA = @INSTALL_DATA@
88 INSTALL_PROGRAM = @INSTALL_PROGRAM@
89 INSTALL_SCRIPT = @INSTALL_SCRIPT@
90 INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
91 INTLLIBS = @INTLLIBS@
92 INTL_MACOSX_LIBS = @INTL_MACOSX_LIBS@
93 LDFLAGS = @LDFLAGS@
94 LIBICONV = @LIBICONV@
95 LIBINTL = @LIBINTL@
96 LIBOBJS = @LIBOBJS@
97 LIBS = @LIBS@
98 LIBTOOL = @LIBTOOL@
99 LN_S = @LN_S@
100 LTLIBICONV = @LTLIBICONV@
101 LTLIBINTL = @LTLIBINTL@
102 LTLIBOBJS = @LTLIBOBJS@
103 MAINT = @MAINT@
104 MAINTAINER_MODE_FALSE = @MAINTAINER_MODE_FALSE@
105 MAINTAINER_MODE_TRUE = @MAINTAINER_MODE_TRUE@
106 MAKEINFO = @MAKEINFO@
107 MSGFMT = @MSGFMT@
108 MSGFMT_015 = @MSGFMT_015@
109 MSGMERGE = @MSGMERGE@
110 OBJEXT = @OBJEXT@
111 PACKAGE = @PACKAGE@
112 PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
113 PACKAGE_NAME = @PACKAGE_NAME@
114 PACKAGE_STRING = @PACKAGE_STRING@
115 PACKAGE_TARNAME = @PACKAGE_TARNAME@
116 PACKAGE_VERSION = @PACKAGE_VERSION@
117 PATH_SEPARATOR = @PATH_SEPARATOR@
118 PA_MODULES_PATH = @PA_MODULES_PATH@
119 PA_VERSION = @PA_VERSION@
120 PE_CFLAGS = @PE_CFLAGS@
121 PE_MODULES_PATH = @PE_MODULES_PATH@
122 PH_CONFIG_PATH = @PH_CONFIG_PATH@
123 PH_MODULES_PATH = @PH_MODULES_PATH@
124 PKG_CONFIG = @PKG_CONFIG@
125 POSUB = @POSUB@
126 PY_CFLAGS = @PY_CFLAGS@
127 PY_MODULES_PATH = @PY_MODULES_PATH@
128 PY_VERSION = @PY_VERSION@
129 RANLIB = @RANLIB@
130 RU_CFLAGS = @RU_CFLAGS@
131 RU_MODULES_PATH = @RU_MODULES_PATH@
132 RU_VERSION = @RU_VERSION@
133 SED = @SED@
134 SET_MAKE = @SET_MAKE@
135 SHELL = @SHELL@
136 STRIP = @STRIP@
137 USE_NLS = @USE_NLS@
138 VERSION = @VERSION@
139 VERSION_INFO = @VERSION_INFO@
140 WITH_HCAL_FALSE = @WITH_HCAL_FALSE@
141 WITH_HCAL_TRUE = @WITH_HCAL_TRUE@
142 WITH_PASCAL_FALSE = @WITH_PASCAL_FALSE@
143 WITH_PASCAL_TRUE = @WITH_PASCAL_TRUE@
144 WITH_PERL_FALSE = @WITH_PERL_FALSE@
145 WITH_PERL_TRUE = @WITH_PERL_TRUE@
146 WITH_PHP_FALSE = @WITH_PHP_FALSE@
147 WITH_PHP_TRUE = @WITH_PHP_TRUE@
148 WITH_PYTHON_FALSE = @WITH_PYTHON_FALSE@
149 WITH_PYTHON_TRUE = @WITH_PYTHON_TRUE@
150 WITH_RUBY_FALSE = @WITH_RUBY_FALSE@
151 WITH_RUBY_TRUE = @WITH_RUBY_TRUE@
152 XGETTEXT = @XGETTEXT@
153 XGETTEXT_015 = @XGETTEXT_015@
154 XGETTEXT_EXTRA_OPTIONS = @XGETTEXT_EXTRA_OPTIONS@
155 ac_ct_CC = @ac_ct_CC@
156 ac_ct_CXX = @ac_ct_CXX@
157 ac_ct_F77 = @ac_ct_F77@
158 am__fastdepCC_FALSE = @am__fastdepCC_FALSE@
159 am__fastdepCC_TRUE = @am__fastdepCC_TRUE@
160 am__fastdepCXX_FALSE = @am__fastdepCXX_FALSE@
161 am__fastdepCXX_TRUE = @am__fastdepCXX_TRUE@
162 am__include = @am__include@
163 am__leading_dot = @am__leading_dot@
164 am__quote = @am__quote@
165 am__tar = @am__tar@
166 am__untar = @am__untar@
167 bindir = @bindir@
168 build = @build@
169 build_alias = @build_alias@
170 build_cpu = @build_cpu@
171 build_os = @build_os@
172 build_vendor = @build_vendor@
173 datadir = @datadir@
174 datarootdir = @datarootdir@
175 docdir = @docdir@
176 dvidir = @dvidir@
177 exec_prefix = @exec_prefix@
178 have_pascal = @have_pascal@
179 have_perl = @have_perl@
180 have_php = @have_php@
181 have_php_config = @have_php_config@
182 have_python = @have_python@
183 have_ruby = @have_ruby@
184 have_swig = @have_swig@
185 host = @host@
186 host_alias = @host_alias@
187 host_cpu = @host_cpu@
188 host_os = @host_os@
189 host_vendor = @host_vendor@
190 htmldir = @htmldir@
191 includedir = @includedir@
192 infodir = @infodir@
193 install_sh = @install_sh@
194 libdir = @libdir@
195 libexecdir = @libexecdir@
196 localedir = @localedir@
197 localstatedir = @localstatedir@
198 mandir = @mandir@
199 mkdir_p = @mkdir_p@
200 oldincludedir = @oldincludedir@
201 pdfdir = @pdfdir@
202 prefix = @prefix@
203 program_transform_name = @program_transform_name@
204 psdir = @psdir@
205 sbindir = @sbindir@
206 sharedstatedir = @sharedstatedir@
207 sysconfdir = @sysconfdir@
208 target_alias = @target_alias@
209 EXTRA_DIST = hdate.i
210 @WITH_RUBY_TRUE@DEPS = $(top_builddir)/src/libhdate.la
211 @WITH_RUBY_TRUE@CLEANFILES = *.o *.cxx *.so *wrap*
212 all: all-am
213
214 .SUFFIXES:
215 $(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(am__configure_deps)
216 @for dep in $?; do \
217 case '$(am__configure_deps)' in \
218 *$$dep*) \
219 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh \
220 && exit 0; \
221 exit 1;; \
222 esac; \
223 done; \
224 echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu bindings/ruby/Makefile'; \
225 cd $(top_srcdir) && \
226 $(AUTOMAKE) --gnu bindings/ruby/Makefile
227 .PRECIOUS: Makefile
228 Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
229 @case '$?' in \
230 *config.status*) \
231 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \
232 *) \
233 echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \
234 cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \
235 esac;
236
237 $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
238 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
239
240 $(top_srcdir)/configure: @MAINTAINER_MODE_TRUE@ $(am__configure_deps)
241 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
242 $(ACLOCAL_M4): @MAINTAINER_MODE_TRUE@ $(am__aclocal_m4_deps)
243 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
244
245 mostlyclean-libtool:
246 -rm -f *.lo
247
248 clean-libtool:
249 -rm -rf .libs _libs
250
251 distclean-libtool:
252 -rm -f libtool
253 uninstall-info-am:
254 tags: TAGS
255 TAGS:
256
257 ctags: CTAGS
258 CTAGS:
259
260
261 distdir: $(DISTFILES)
262 @srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; \
263 topsrcdirstrip=`echo "$(top_srcdir)" | sed 's|.|.|g'`; \
264 list='$(DISTFILES)'; for file in $$list; do \
265 case $$file in \
266 $(srcdir)/*) file=`echo "$$file" | sed "s|^$$srcdirstrip/||"`;; \
267 $(top_srcdir)/*) file=`echo "$$file" | sed "s|^$$topsrcdirstrip/|$(top_builddir)/|"`;; \
268 esac; \
269 if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
270 dir=`echo "$$file" | sed -e 's,/[^/]*$$,,'`; \
271 if test "$$dir" != "$$file" && test "$$dir" != "."; then \
272 dir="/$$dir"; \
273 $(mkdir_p) "$(distdir)$$dir"; \
274 else \
275 dir=''; \
276 fi; \
277 if test -d $$d/$$file; then \
278 if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
279 cp -pR $(srcdir)/$$file $(distdir)$$dir || exit 1; \
280 fi; \
281 cp -pR $$d/$$file $(distdir)$$dir || exit 1; \
282 else \
283 test -f $(distdir)/$$file \
284 || cp -p $$d/$$file $(distdir)/$$file \
285 || exit 1; \
286 fi; \
287 done
288 check-am: all-am
289 check: check-am
290 all-am: Makefile
291 installdirs:
292 install: install-am
293 install-exec: install-exec-am
294 install-data: install-data-am
295 uninstall: uninstall-am
296
297 install-am: all-am
298 @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
299
300 installcheck: installcheck-am
301 install-strip:
302 $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
303 install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
304 `test -z '$(STRIP)' || \
305 echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install
306 mostlyclean-generic:
307
308 clean-generic:
309 -test -z "$(CLEANFILES)" || rm -f $(CLEANFILES)
310
311 distclean-generic:
312 -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
313
314 maintainer-clean-generic:
315 @echo "This command is intended for maintainers to use"
316 @echo "it deletes files that may require special tools to rebuild."
317 @WITH_RUBY_FALSE@install-data-local:
318 clean: clean-am
319
320 clean-am: clean-generic clean-libtool mostlyclean-am
321
322 distclean: distclean-am
323 -rm -f Makefile
324 distclean-am: clean-am distclean-generic distclean-libtool
325
326 dvi: dvi-am
327
328 dvi-am:
329
330 html: html-am
331
332 info: info-am
333
334 info-am:
335
336 install-data-am: install-data-local
337
338 install-exec-am:
339
340 install-info: install-info-am
341
342 install-man:
343
344 installcheck-am:
345
346 maintainer-clean: maintainer-clean-am
347 -rm -f Makefile
348 maintainer-clean-am: distclean-am maintainer-clean-generic
349
350 mostlyclean: mostlyclean-am
351
352 mostlyclean-am: mostlyclean-generic mostlyclean-libtool
353
354 pdf: pdf-am
355
356 pdf-am:
357
358 ps: ps-am
359
360 ps-am:
361
362 uninstall-am: uninstall-info-am
363
364 .PHONY: all all-am check check-am clean clean-generic clean-libtool \
365 distclean distclean-generic distclean-libtool distdir dvi \
366 dvi-am html html-am info info-am install install-am \
367 install-data install-data-am install-data-local install-exec \
368 install-exec-am install-info install-info-am install-man \
369 install-strip installcheck installcheck-am installdirs \
370 maintainer-clean maintainer-clean-generic mostlyclean \
371 mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \
372 uninstall uninstall-am uninstall-info-am
373
374
375 @WITH_RUBY_TRUE@all-am: hdate.so
376
377 @WITH_RUBY_TRUE@hdate.so: hdate_wrap.cxx
378 @WITH_RUBY_TRUE@ g++ -fpic -fno-strict-aliasing -g -O2 -c hdate_wrap.cxx $(RU_CFLAGS) -I$(top_srcdir)/src
379 @WITH_RUBY_TRUE@ gcc -shared ../../src/.libs/libhdate.so hdate_wrap.o -rdynamic -Wl,-export-dynamic -lruby$(RU_VERSION) -lpthread -ldl -lcrypt -lm -lc -lstdc++ -o hdate.so
380
381 @WITH_RUBY_TRUE@hdate_wrap.cxx: hdate.i
382 @WITH_RUBY_TRUE@ swig -c++ -ruby hdate.i
383
384 @WITH_RUBY_TRUE@install-data-local: hdate.so
385 @WITH_RUBY_TRUE@ $(mkinstalldirs) $(DESTDIR)$(RU_MODULES_PATH)
386 @WITH_RUBY_TRUE@ $(INSTALL_DATA) hdate.so $(DESTDIR)$(RU_MODULES_PATH)/hdate.so
387 # Tell versions [3.59,3.63) of GNU make to not export all variables.
388 # Otherwise a system limit (for SysV at least) may be exceeded.
389 .NOEXPORT:
0 // file : hdate.i
1 %module hdate
2 %{
3 #include "../../src/hdatepp.h"
4 %}
5
6 %include ../../src/hdatepp.h
7
8
885885 PY_MODULES_PATH
886886 WITH_PYTHON_TRUE
887887 WITH_PYTHON_FALSE
888 have_ruby
889 RU_VERSION
890 RU_CFLAGS
891 RU_MODULES_PATH
892 WITH_RUBY_TRUE
893 WITH_RUBY_FALSE
894 have_php
895 have_php_config
896 PH_CONFIG_PATH
897 PH_MODULES_PATH
898 WITH_PHP_TRUE
899 WITH_PHP_FALSE
888900 have_perl
889901 PE_CFLAGS
890902 PE_MODULES_PATH
15161528 --disable-libtool-lock avoid locking (might break parallel builds)
15171529 --disable-pascal do not build pascal binding
15181530 --disable-python do not build python binding
1531 --disable-ruby do not build ruby binding
1532 --disable-php do not build php binding
15191533 --disable-perl do not build perl binding
15201534 --disable-nls do not use Native Language Support
15211535 --disable-rpath do not hardcode runtime library paths
15301544 --with-tags[=TAGS] include additional configurations [automatic]
15311545 --with-python-sitelib-dir=PATH
15321546 path to python site lib
1547 --with-ruby-sitelib-dir=PATH
1548 path to ruby site lib
1549 --with-php-sitelib-dir=PATH
1550 path to php site lib
15331551 --with-perl-sitelib-dir=PATH
15341552 path to perl site lib
15351553 --with-gnu-ld assume the C compiler uses GNU ld default=no
19801998 PACKAGE=libhdate
19811999 LIBHDATE_MAJOR_VERSION=1
19822000 LIBHDATE_MINOR_VERSION=4
1983 LIBHDATE_MICRO_VERSION=10
2001 LIBHDATE_MICRO_VERSION=11
19842002
19852003 VERSION=$LIBHDATE_MAJOR_VERSION.$LIBHDATE_MINOR_VERSION.$LIBHDATE_MICRO_VERSION
19862004
62636281 ;;
62646282 *-*-irix6*)
62656283 # Find out which ABI we are using.
6266 echo '#line 6267 "configure"' > conftest.$ac_ext
6284 echo '#line 6285 "configure"' > conftest.$ac_ext
62676285 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
62686286 (eval $ac_compile) 2>&5
62696287 ac_status=$?
85278545 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
85288546 -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
85298547 -e 's:$: $lt_compiler_flag:'`
8530 (eval echo "\"\$as_me:8531: $lt_compile\"" >&5)
8548 (eval echo "\"\$as_me:8549: $lt_compile\"" >&5)
85318549 (eval "$lt_compile" 2>conftest.err)
85328550 ac_status=$?
85338551 cat conftest.err >&5
8534 echo "$as_me:8535: \$? = $ac_status" >&5
8552 echo "$as_me:8553: \$? = $ac_status" >&5
85358553 if (exit $ac_status) && test -s "$ac_outfile"; then
85368554 # The compiler can only warn and ignore the option if not recognized
85378555 # So say no if there are warnings other than the usual output.
88178835 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
88188836 -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
88198837 -e 's:$: $lt_compiler_flag:'`
8820 (eval echo "\"\$as_me:8821: $lt_compile\"" >&5)
8838 (eval echo "\"\$as_me:8839: $lt_compile\"" >&5)
88218839 (eval "$lt_compile" 2>conftest.err)
88228840 ac_status=$?
88238841 cat conftest.err >&5
8824 echo "$as_me:8825: \$? = $ac_status" >&5
8842 echo "$as_me:8843: \$? = $ac_status" >&5
88258843 if (exit $ac_status) && test -s "$ac_outfile"; then
88268844 # The compiler can only warn and ignore the option if not recognized
88278845 # So say no if there are warnings other than the usual output.
89218939 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
89228940 -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
89238941 -e 's:$: $lt_compiler_flag:'`
8924 (eval echo "\"\$as_me:8925: $lt_compile\"" >&5)
8942 (eval echo "\"\$as_me:8943: $lt_compile\"" >&5)
89258943 (eval "$lt_compile" 2>out/conftest.err)
89268944 ac_status=$?
89278945 cat out/conftest.err >&5
8928 echo "$as_me:8929: \$? = $ac_status" >&5
8946 echo "$as_me:8947: \$? = $ac_status" >&5
89298947 if (exit $ac_status) && test -s out/conftest2.$ac_objext
89308948 then
89318949 # The compiler can only warn and ignore the option if not recognized
1128311301 lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
1128411302 lt_status=$lt_dlunknown
1128511303 cat > conftest.$ac_ext <<EOF
11286 #line 11287 "configure"
11304 #line 11305 "configure"
1128711305 #include "confdefs.h"
1128811306
1128911307 #if HAVE_DLFCN_H
1138311401 lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
1138411402 lt_status=$lt_dlunknown
1138511403 cat > conftest.$ac_ext <<EOF
11386 #line 11387 "configure"
11404 #line 11405 "configure"
1138711405 #include "confdefs.h"
1138811406
1138911407 #if HAVE_DLFCN_H
1380313821 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
1380413822 -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
1380513823 -e 's:$: $lt_compiler_flag:'`
13806 (eval echo "\"\$as_me:13807: $lt_compile\"" >&5)
13824 (eval echo "\"\$as_me:13825: $lt_compile\"" >&5)
1380713825 (eval "$lt_compile" 2>conftest.err)
1380813826 ac_status=$?
1380913827 cat conftest.err >&5
13810 echo "$as_me:13811: \$? = $ac_status" >&5
13828 echo "$as_me:13829: \$? = $ac_status" >&5
1381113829 if (exit $ac_status) && test -s "$ac_outfile"; then
1381213830 # The compiler can only warn and ignore the option if not recognized
1381313831 # So say no if there are warnings other than the usual output.
1390713925 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
1390813926 -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
1390913927 -e 's:$: $lt_compiler_flag:'`
13910 (eval echo "\"\$as_me:13911: $lt_compile\"" >&5)
13928 (eval echo "\"\$as_me:13929: $lt_compile\"" >&5)
1391113929 (eval "$lt_compile" 2>out/conftest.err)
1391213930 ac_status=$?
1391313931 cat out/conftest.err >&5
13914 echo "$as_me:13915: \$? = $ac_status" >&5
13932 echo "$as_me:13933: \$? = $ac_status" >&5
1391513933 if (exit $ac_status) && test -s out/conftest2.$ac_objext
1391613934 then
1391713935 # The compiler can only warn and ignore the option if not recognized
1548415502 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
1548515503 -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
1548615504 -e 's:$: $lt_compiler_flag:'`
15487 (eval echo "\"\$as_me:15488: $lt_compile\"" >&5)
15505 (eval echo "\"\$as_me:15506: $lt_compile\"" >&5)
1548815506 (eval "$lt_compile" 2>conftest.err)
1548915507 ac_status=$?
1549015508 cat conftest.err >&5
15491 echo "$as_me:15492: \$? = $ac_status" >&5
15509 echo "$as_me:15510: \$? = $ac_status" >&5
1549215510 if (exit $ac_status) && test -s "$ac_outfile"; then
1549315511 # The compiler can only warn and ignore the option if not recognized
1549415512 # So say no if there are warnings other than the usual output.
1558815606 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
1558915607 -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
1559015608 -e 's:$: $lt_compiler_flag:'`
15591 (eval echo "\"\$as_me:15592: $lt_compile\"" >&5)
15609 (eval echo "\"\$as_me:15610: $lt_compile\"" >&5)
1559215610 (eval "$lt_compile" 2>out/conftest.err)
1559315611 ac_status=$?
1559415612 cat out/conftest.err >&5
15595 echo "$as_me:15596: \$? = $ac_status" >&5
15613 echo "$as_me:15614: \$? = $ac_status" >&5
1559615614 if (exit $ac_status) && test -s out/conftest2.$ac_objext
1559715615 then
1559815616 # The compiler can only warn and ignore the option if not recognized
1778817806 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
1778917807 -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
1779017808 -e 's:$: $lt_compiler_flag:'`
17791 (eval echo "\"\$as_me:17792: $lt_compile\"" >&5)
17809 (eval echo "\"\$as_me:17810: $lt_compile\"" >&5)
1779217810 (eval "$lt_compile" 2>conftest.err)
1779317811 ac_status=$?
1779417812 cat conftest.err >&5
17795 echo "$as_me:17796: \$? = $ac_status" >&5
17813 echo "$as_me:17814: \$? = $ac_status" >&5
1779617814 if (exit $ac_status) && test -s "$ac_outfile"; then
1779717815 # The compiler can only warn and ignore the option if not recognized
1779817816 # So say no if there are warnings other than the usual output.
1807818096 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
1807918097 -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
1808018098 -e 's:$: $lt_compiler_flag:'`
18081 (eval echo "\"\$as_me:18082: $lt_compile\"" >&5)
18099 (eval echo "\"\$as_me:18100: $lt_compile\"" >&5)
1808218100 (eval "$lt_compile" 2>conftest.err)
1808318101 ac_status=$?
1808418102 cat conftest.err >&5
18085 echo "$as_me:18086: \$? = $ac_status" >&5
18103 echo "$as_me:18104: \$? = $ac_status" >&5
1808618104 if (exit $ac_status) && test -s "$ac_outfile"; then
1808718105 # The compiler can only warn and ignore the option if not recognized
1808818106 # So say no if there are warnings other than the usual output.
1818218200 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
1818318201 -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
1818418202 -e 's:$: $lt_compiler_flag:'`
18185 (eval echo "\"\$as_me:18186: $lt_compile\"" >&5)
18203 (eval echo "\"\$as_me:18204: $lt_compile\"" >&5)
1818618204 (eval "$lt_compile" 2>out/conftest.err)
1818718205 ac_status=$?
1818818206 cat out/conftest.err >&5
18189 echo "$as_me:18190: \$? = $ac_status" >&5
18207 echo "$as_me:18208: \$? = $ac_status" >&5
1819018208 if (exit $ac_status) && test -s out/conftest2.$ac_objext
1819118209 then
1819218210 # The compiler can only warn and ignore the option if not recognized
2122921247 else
2123021248 WITH_PYTHON_TRUE='#'
2123121249 WITH_PYTHON_FALSE=
21250 fi
21251
21252
21253
21254 # Extract the first word of ""ruby"", so it can be a program name with args.
21255 set dummy "ruby"; ac_word=$2
21256 { echo "$as_me:$LINENO: checking for $ac_word" >&5
21257 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
21258 if test "${ac_cv_prog_have_ruby+set}" = set; then
21259 echo $ECHO_N "(cached) $ECHO_C" >&6
21260 else
21261 if test -n "$have_ruby"; then
21262 ac_cv_prog_have_ruby="$have_ruby" # Let the user override the test.
21263 else
21264 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
21265 for as_dir in $PATH
21266 do
21267 IFS=$as_save_IFS
21268 test -z "$as_dir" && as_dir=.
21269 for ac_exec_ext in '' $ac_executable_extensions; do
21270 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
21271 ac_cv_prog_have_ruby="yes"
21272 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
21273 break 2
21274 fi
21275 done
21276 done
21277 IFS=$as_save_IFS
21278
21279 test -z "$ac_cv_prog_have_ruby" && ac_cv_prog_have_ruby="no"
21280 fi
21281 fi
21282 have_ruby=$ac_cv_prog_have_ruby
21283 if test -n "$have_ruby"; then
21284 { echo "$as_me:$LINENO: result: $have_ruby" >&5
21285 echo "${ECHO_T}$have_ruby" >&6; }
21286 else
21287 { echo "$as_me:$LINENO: result: no" >&5
21288 echo "${ECHO_T}no" >&6; }
21289 fi
21290
21291
21292
21293 build_ruby=$have_ruby
21294
21295 # Check whether --enable-ruby was given.
21296 if test "${enable_ruby+set}" = set; then
21297 enableval=$enable_ruby; build_ruby=no
21298 else
21299 build_ruby=$have_ruby
21300 fi
21301
21302
21303
21304 # Check whether --with-ruby-sitelib-dir was given.
21305 if test "${with_ruby_sitelib_dir+set}" = set; then
21306 withval=$with_ruby_sitelib_dir;
21307 fi
21308
21309
21310 if test "$have_ruby" = "yes"; then
21311 RU_PREFIX=`ruby -e 'require "mkmf"; puts $topdir'`
21312 RU_VERSION=`ruby -e "require 'mkmf'; puts config_string('MAJOR')"`
21313 RU_VERSION+=.`ruby -e "require 'mkmf'; puts config_string('MINOR')"`
21314 { echo "$as_me:$LINENO: checking for $RU_PREFIX/ruby.h" >&5
21315 echo $ECHO_N "checking for $RU_PREFIX/ruby.h... $ECHO_C" >&6; }
21316 if test -f $RU_PREFIX/ruby.h; then
21317 { echo "$as_me:$LINENO: result: yes" >&5
21318 echo "${ECHO_T}yes" >&6; }
21319 RU_CFLAGS="-I$RU_PREFIX"
21320
21321 if test "$with_ruby_sitelib_dir" = "" ; then
21322 RU_MODULES_PATH="$RU_PREFIX"
21323 else
21324 RU_MODULES_PATH=$with_ruby_sitelib_dir
21325 fi
21326
21327
21328
21329
21330 if test "$have_swig" = "no"; then
21331 build_ruby=no
21332 fi
21333 else
21334 { echo "$as_me:$LINENO: result: no" >&5
21335 echo "${ECHO_T}no" >&6; }
21336 build_ruby=no
21337 fi
21338 fi
21339
21340
21341
21342 if test "$build_ruby" = "yes"; then
21343 WITH_RUBY_TRUE=
21344 WITH_RUBY_FALSE='#'
21345 else
21346 WITH_RUBY_TRUE='#'
21347 WITH_RUBY_FALSE=
21348 fi
21349
21350
21351
21352 # Extract the first word of ""php"", so it can be a program name with args.
21353 set dummy "php"; ac_word=$2
21354 { echo "$as_me:$LINENO: checking for $ac_word" >&5
21355 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
21356 if test "${ac_cv_prog_have_php+set}" = set; then
21357 echo $ECHO_N "(cached) $ECHO_C" >&6
21358 else
21359 if test -n "$have_php"; then
21360 ac_cv_prog_have_php="$have_php" # Let the user override the test.
21361 else
21362 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
21363 for as_dir in $PATH
21364 do
21365 IFS=$as_save_IFS
21366 test -z "$as_dir" && as_dir=.
21367 for ac_exec_ext in '' $ac_executable_extensions; do
21368 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
21369 ac_cv_prog_have_php="yes"
21370 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
21371 break 2
21372 fi
21373 done
21374 done
21375 IFS=$as_save_IFS
21376
21377 test -z "$ac_cv_prog_have_php" && ac_cv_prog_have_php="no"
21378 fi
21379 fi
21380 have_php=$ac_cv_prog_have_php
21381 if test -n "$have_php"; then
21382 { echo "$as_me:$LINENO: result: $have_php" >&5
21383 echo "${ECHO_T}$have_php" >&6; }
21384 else
21385 { echo "$as_me:$LINENO: result: no" >&5
21386 echo "${ECHO_T}no" >&6; }
21387 fi
21388
21389
21390
21391 build_php=$have_php
21392
21393 # Check whether --enable-php was given.
21394 if test "${enable_php+set}" = set; then
21395 enableval=$enable_php; build_php=no
21396 else
21397 build_php=$have_php
21398 fi
21399
21400
21401
21402 # Check whether --with-php-sitelib-dir was given.
21403 if test "${with_php_sitelib_dir+set}" = set; then
21404 withval=$with_php_sitelib_dir;
21405 fi
21406
21407
21408 if test "$have_php" = "yes"; then
21409 # Extract the first word of ""php-config5"", so it can be a program name with args.
21410 set dummy "php-config5"; ac_word=$2
21411 { echo "$as_me:$LINENO: checking for $ac_word" >&5
21412 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
21413 if test "${ac_cv_prog_have_php_config+set}" = set; then
21414 echo $ECHO_N "(cached) $ECHO_C" >&6
21415 else
21416 if test -n "$have_php_config"; then
21417 ac_cv_prog_have_php_config="$have_php_config" # Let the user override the test.
21418 else
21419 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
21420 for as_dir in $PATH
21421 do
21422 IFS=$as_save_IFS
21423 test -z "$as_dir" && as_dir=.
21424 for ac_exec_ext in '' $ac_executable_extensions; do
21425 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
21426 ac_cv_prog_have_php_config="yes"
21427 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
21428 break 2
21429 fi
21430 done
21431 done
21432 IFS=$as_save_IFS
21433
21434 test -z "$ac_cv_prog_have_php_config" && ac_cv_prog_have_php_config="no"
21435 fi
21436 fi
21437 have_php_config=$ac_cv_prog_have_php_config
21438 if test -n "$have_php_config"; then
21439 { echo "$as_me:$LINENO: result: $have_php_config" >&5
21440 echo "${ECHO_T}$have_php_config" >&6; }
21441 else
21442 { echo "$as_me:$LINENO: result: no" >&5
21443 echo "${ECHO_T}no" >&6; }
21444 fi
21445
21446
21447 if test "$have_php_config" = "yes"; then
21448
21449 PH_CONFIG_PATH=`php --ini | head -n1 | cut -d: -f2 | sed 's/\s//g'`
21450 if test "$with_php_sitelib_dir" = "" ; then
21451 PH_MODULES_PATH=`php-config5 --extension-dir`
21452 else
21453 PH_MODULES_PATH=$with_php_sitelib_dir
21454 fi
21455
21456
21457
21458 if test "$have_swig" = "no"; then
21459 build_php=no
21460 fi
21461 else
21462 { echo "$as_me:$LINENO: result: no" >&5
21463 echo "${ECHO_T}no" >&6; }
21464 build_php=no
21465 fi