source: git/omalloc/configure.ac @ 444bcf

spielwiese
Last change on this file since 444bcf was 444bcf, checked in by Oleksandr Motsak <motsak@…>, 12 years ago
CHG: minor cleanup ADD: original Hans's test for standalone testing: tt.cc FIX: typo
  • Property mode set to 100644
File size: 16.6 KB
Line 
1dnl lllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllll
2dnl File: configure.ac
3dnl Purpose: Process this file with autoconf to produce configure
4dnl Author:  obachman@mathematik.uni-kl.de (Olaf Bachmann)
5dnl Created: 11/99
6dnl Version: $Id$
7dnl lllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllll
8
9AC_INIT([omalloc],[0.9.6])
10AC_CONFIG_SRCDIR(om_Alloc.c)
11
12AC_CONFIG_AUX_DIR([.])
13
14AC_CONFIG_HEADER(omConfig.h)
15
16AM_MAINTAINER_MODE
17AM_INIT_AUTOMAKE([omalloc],[0.9.6])
18
19# Add pre'prefixed config
20AX_PREFIX_CONFIG_H([omConfig.h],[],[omConfig.h])
21
22AC_SUBST(VERSION)
23
24dnl lllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllll
25dnl help for configure
26dnl
27AC_ARG_WITH(
28  external-config_h,
29  [ --with-external-config_h=HEADER_FILE
30                    use HEADER_FILE for external configuration])
31AC_ARG_WITH(
32  external-config_c,
33  [ --with-external-config_c=C_FILE
34                    use C_FILE for external implementations])
35AC_ARG_WITH(
36  malloc,
37  [ --with-malloc=system|external
38                    which malloc to use, default: malloc ])
39AC_ARG_WITH(
40  external-malloc_h,
41  [ --with-external-malloc-h=HEADER_FILE
42                    use HEADER_FILE for external malloc declaration])
43AC_ARG_WITH(
44  external-malloc_c,
45  [ --with-external-malloc-c=C_FILE
46                    use C_FILE for external malloc implementation])
47AC_ARG_WITH(
48  valloc,
49  [ --with-valloc=mmap|system|emulate
50                    how to get page-aligned memory, default: use first possible])
51AC_ARG_WITH(
52  align,
53  [ --with-align=8|sloppy|strict
54                    how memory is aligned,
55                    default: if possible sloppy, else strict])
56AC_ARG_WITH(
57  dense-bins,
58  [ --with-dense-bins  use dense bin distribution])
59AC_ARG_WITH(
60  inline,
61  [ --without-inline   do not inline])
62AC_ARG_WITH(
63  debug,
64  [ --without-debug    disable all debugging facilities])
65AC_ARG_WITH(
66  track,
67  [ --without-track    disable debug tracking functionality])
68AC_ARG_WITH(
69  track-fl,
70  [ --with-track-fl    track file and line numbers])
71AC_ARG_WITH(
72  track-return,
73  [ --with-track-return track return addresses])
74AC_ARG_WITH(
75  track-backtrace,
76  [ --with-track-backtrace track stack backtraces])
77AC_ARG_WITH(
78  track-custom,
79  [ --with-track-custom track custom values])
80AC_ARG_WITH(
81  internal_debug,
82  [ --with-internal-debug
83                       turn on internal debugging])
84dnl lllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllll
85dnl compiler/make  config
86dnl
87dnl I'm not sure why I did this
88dnl if test "${CFLAGS+set}" != set; then
89dnl  CFLAGS="-O"
90dnl  ac_cflags_set=no
91dnl fi
92
93CPPFLAGS="-I.. -I."
94AC_PROG_MAKE_SET
95AC_PROG_CC
96AC_PROG_CPP
97
98AC_PROG_LN_S
99AC_PROG_INSTALL
100AM_PROG_CC_C_O
101AC_C_CONST
102AC_C_INLINE
103
104LT_INIT
105
106
107dnl lllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllll
108dnl check for programs
109dnl
110AC_CHECK_PROG(AR, ar, ar, :)
111if test "$ac_cv_prog_AR" != ar; then
112  AC_MSG_ERROR(*** ar program not found)
113fi
114AC_CHECK_PROGS(PERL, perl, "no")
115if test "$ac_cv_prog_PERL" = no; then
116  AC_MSG_ERROR(*** perl program not found)
117fi
118
119AC_CHECK_PROG(ADDR2LINE, addr2line, addr2line, no)
120if test "$ac_cv_prog_ADDR2LINE" = addr2line; then
121  AC_DEFINE_UNQUOTED(OM_PROG_ADDR2LINE, "$ac_cv_prog_ADDR2LINE", "Name of addr2line")
122fi
123
124dnl lllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllll
125dnl header file checks
126dnl
127AC_HEADER_STDC
128AC_CHECK_HEADERS(limits.h,,
129  AC_MSG_ERROR(Can not compile without limits.h))
130AC_CHECK_HEADERS(unistd.h sys/mman.h fcntl.h /usr/include/malloc.h)
131
132AC_CHECK_FUNCS(popen readlink getcwd getwd mmap sbrk random)
133
134dnl llllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllll
135dnl Find out more about particularity of the system
136dnl
137
138# sizes
139AC_CHECK_SIZEOF(long,4)
140AC_CHECK_SIZEOF(void*,4)
141AC_CHECK_SIZEOF(double, 8)
142AC_CHECK_SIZEOF(size_t, 4)
143
144if test "$ac_cv_sizeof_long" != "$ac_cv_sizeof_voidp"; then
145  AC_MSG_ERROR(need equal sizes for long and void*)
146fi
147if test "$ac_cv_sizeof_voidp" != 4 && test "$ac_cv_sizeof_voidp" != 8; then
148  AC_MSG_ERROR(need void* to be 4 or 8 bytes long)
149fi
150if test "$ac_cv_sizeof_double" != 4 && test "$ac_cv_sizeof_double" != 8; then
151  AC_MSG_ERROR(need double to be 4 or 8 bytes long)
152fi
153
154dnl Set compiler, linker flags so that we can work with omalloc
155BACKUP_CFLAGS=$CFLAGS
156BACKUP_CXXFLAGS=$CXXFLAGS
157BACKUP_LDFLAGS=$LDFLAGS
158CFLAGS="$CFLAGS -I$srcdir"
159CXXFLAGS="$CXXFLAGS -I$srcdir"
160
161dnl lllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllll
162dnl figure out page size of the system
163dnl
164AC_MSG_CHECKING(size of system page)
165AC_CACHE_VAL(ac_cv_pagesize,
166AC_TRY_RUN([#include <stdio.h>
167#include "omGetPageSize.h"
168
169main()
170{
171  FILE *f=fopen("conftestval", "w");
172  if (!f) exit(1);
173  fprintf(f, "%d\n", omalloc_getpagesize);
174  exit(0);
175}], ac_cv_pagesize=`cat conftestval`, ac_cv_pagesize=0, ac_cv_pagesize=0))
176# can not really handle pagesizes which are greater -- there must be a
177# bug somewhere
178if test $ac_cv_pagesize -gt 8192; then
179  ac_cv_pagesize=8192
180fi
181AC_MSG_RESULT($ac_cv_pagesize)
182if test "$ac_cv_pagesize" = 4096 || test "$ac_cv_pagesize" = 8192; then
183  AC_DEFINE_UNQUOTED(SIZEOF_SYSTEM_PAGE, $ac_cv_pagesize, "Page-size of the build-system")
184else
185AC_MSG_ERROR([need sytem page to be of size 4096 or 8192, but is $ac_cv_pagesize])
186fi
187
188AC_DEFINE_UNQUOTED(SIZEOF_OM_PAGE,SIZEOF_SYSTEM_PAGE,Page-size of the build-system)
189
190dnl lllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllll
191dnl check whether mmap actually works
192dnl
193if test "$ac_cv_func_mmap" = yes; then
194AC_MSG_CHECKING(whether mmap works)
195AC_CACHE_VAL(ac_cv_working_mmap,
196AC_TRY_RUN([
197#include "omMmap.c"
198main()
199{
200  void* addr = omVallocMmap(128*${ac_cv_pagesize});
201  if (addr == 0 || ((unsigned long) addr % ${ac_cv_pagesize}))
202    exit(1);
203  exit(omVfreeMmap(addr, 128*${ac_cv_pagesize}));
204}], ac_cv_working_mmap=yes, ac_cv_working_mmap=no, ac_cv_working_mmap=no))
205AC_MSG_RESULT($ac_cv_working_mmap)
206if test "$ac_cv_working_mmap" = yes; then
207  AC_DEFINE(HAVE_WORKING_MMAP,1,"Whether we have a working mmap")
208fi
209fi
210
211dnl lllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllll
212dnl for strict alignment
213dnl
214AC_CACHE_CHECK(whether alignment needs to be strict, ac_cv_align_need_strict,
215AC_TRY_RUN([
216main()
217{
218  void* ptr = (void*) malloc(12);
219  double* d_ptr;
220  if ((unsigned long) ptr % 8 == 0) ptr = ptr + 4;
221  d_ptr = (double*) ptr;
222  *d_ptr = (double) 1.1;
223  if (*d_ptr != (double) 1.1) exit(1);
224  else exit(0);
225}
226], ac_cv_align_need_strict=no, ac_cv_align_need_strict=yes, ac_cv_align_need_strict=yes))
227
228dnl lllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllll
229dnl external config files
230dnl
231AC_MSG_CHECKING(for external config files)
232if test "${with_external_config_h+set}" = set; then
233    AC_DEFINE(OM_HAVE_EXTERNAL_CONFIG_H,1,"Whether we have external config.h")
234    EXTERNAL_CONFIG_HEADER=${with_external_config_h}
235    rm -f omExternalConfig.h
236    cp ${with_external_config_h} omExternalConfig.h
237fi
238if test "${with_external_config_c+set}" = set; then
239    AC_DEFINE(OM_HAVE_EXTERNAL_CONFIG_C,1,"Wether we have an external config.c")
240    EXTERNAL_CONFIG_SOURCE=${with_external_config_c}
241fi
242AC_SUBST(EXTERNAL_CONFIG_HEADER)
243AC_SUBST(EXTERNAL_CONFIG_SOURCE)
244if test "${EXTERNAL_CONFIG_HEADER+set}" = set || test "${EXTERNAL_CONFIG_SOURCE+set}" = set; then
245AC_MSG_RESULT(${EXTERNAL_CONFIG_HEADER} ${EXTERNAL_CONFIG_SOURCE})
246else
247AC_MSG_RESULT(none)
248fi
249
250dnl lllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllll
251dnl for malloc
252dnl
253AC_MSG_CHECKING(which malloc to use)
254if test "${with_malloc}" = system; then
255  OM_MALLOC_HEADER=omMallocSystem.h
256  AC_DEFINE(OMALLOC_USES_MALLOC,1,the system allocator is called malloc)
257  AC_DEFINE(OMALLOC_USES_SYSTEM_MALLOC,1,use system malloc as system allocator)
258elif test "${with_malloc}" = external; then
259  if test "${with_external_malloc_h+set}" != set; then
260    AC_MSG_ERROR(need --with_external_malloc_h for external malloc)
261  fi
262  AC_DEFINE(OMALLOC_USES_EXTERNAL_MALLOC,1,use external malloc as system allocator)
263  OM_MALLOC_HEADER=$with_external_malloc_h
264  OM_MALLOC_SOURCE=$with_external_malloc_c
265  AC_DEFINE(OMALLOC_USES_MALLOC,1,the system allocator is called malloc)
266else    ## default
267  OM_MALLOC_HEADER=omMallocSystem.h
268  AC_DEFINE(OMALLOC_USES_MALLOC,1,the system allocator is called malloc)
269  AC_DEFINE(OMALLOC_USES_SYSTEM_MALLOC,1,use system malloc as system allocator)
270fi
271AC_MSG_RESULT($with_malloc)
272
273AC_SUBST(OM_MALLOC_HEADER)
274AC_SUBST(OM_MALLOC_SOURCE)
275if test "${OM_MALLOC_SOURCE+set}" = set; then
276  AC_DEFINE(OM_HAVE_MALLOC_SOURCE,1,"Whether we have the source for malloc ()")
277fi
278
279AC_MSG_CHECKING(whether malloc provides SizeOfAddr)
280if test "${ac_cv_malloc_sizeof_addr}" = no; then
281  AC_MSG_RESULT( (cached) no)
282elif test "${ac_cv_malloc_sizeof_addr}" = "${OM_MALLOC_HEADER}_${OM_MALLOC_SOURCE}"; then
283   AC_MSG_RESULT( (cached) yes)
284else
285AC_TRY_RUN([
286#include "$OM_MALLOC_HEADER"
287#ifdef OM_HAVE_MALLOC_SOURCE
288#include "$OM_MALLOC_SOURCE"
289#endif
290
291main()
292{
293  void* addr = OM_MALLOC_MALLOC(512);
294  if (OM_MALLOC_SIZEOF_ADDR(addr) < 512)
295    exit(1);
296  exit(0);
297}
298], ac_cv_malloc_sizeof_addr="${OM_MALLOC_HEADER}_${OM_MALLOC_SOURCE}", ac_cv_malloc_sizeof_addr=no, ac_cv_malloc_sizeof_addr=no)
299if test "${ac_cv_malloc_sizeof_addr}" = no; then
300AC_MSG_RESULT(no)
301else
302AC_MSG_RESULT(yes)
303fi
304fi
305if test "$ac_cv_malloc_sizeof_addr" != no; then
306AC_DEFINE(OM_MALLOC_PROVIDES_SIZEOF_ADDR,1,"Whether malloc provides SIZEOF_ADDR")
307fi
308
309dnl Restore user-specified CFLAGS, CXXFLAGS, LIBS
310
311CFLAGS=$BACKUP_CFLAGS
312CXXFLAGS=$BACKUP_CXXFLAGS
313LDFLAGS=$BACKUP_LDFLAGS
314
315dnl lllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllll
316dnl check whether valloc is provided and that it works
317dnl
318AC_MSG_CHECKING(whether working valloc exists)
319if test "${ac_cv_working_valloc}" = no; then
320  AC_MSG_RESULT( (cached) no)
321elif test "${ac_cv_working_valloc}" = "${OM_MALLOC_HEADER}_${OM_MALLOC_SOURCE}"; then
322  AC_MSG_RESULT( (cached) yes)
323else
324AC_TRY_RUN([
325#include "$OM_MALLOC_HEADER"
326#ifdef OM_HAVE_MALLOC_SOURCE
327#include "$OM_MALLOC_SOURCE"
328#endif
329
330main()
331{
332  void* addr = OM_MALLOC_VALLOC(128*${ac_cv_pagesize});
333  if (addr == 0 || ((unsigned long) addr % ${ac_cv_pagesize}))
334    exit(1);
335  OM_MALLOC_VFREE(addr, 128*${ac_cv_pagesize});
336  exit(0);
337}
338], ac_cv_working_valloc="${OM_MALLOC_HEADER}_${OM_MALLOC_SOURCE}", ac_cv_working_valloc=no, ac_cv_working_valloc=no)
339if test "${ac_cv_working_valloc}" = no; then
340AC_MSG_RESULT(no)
341else
342AC_MSG_RESULT(yes)
343fi
344fi
345
346dnl lllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllll
347dnl for valloc
348dnl
349AC_MSG_CHECKING(which valloc to use)
350if test "${with_valloc+set}" != set || test "${with_valloc}" = mmap; then
351  if test "${ac_cv_working_mmap}" = yes; then
352    with_valloc=mmap
353    AC_DEFINE(OM_HAVE_VALLOC_MMAP,1,"Have valloc")
354  else
355    with_valloc=malloc
356  fi
357fi
358if test "${with_valloc}" = malloc; then
359  if test "${ac_cv_working_valloc}" != no; then
360    AC_DEFINE(OM_HAVE_VALLOC_MALLOC,1,"Have valloc")
361  else
362    with_valloc=emulate
363  fi
364fi
365AC_MSG_RESULT($with_valloc)
366
367dnl lllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllll
368dnl alignment
369dnl
370AC_MSG_CHECKING(how to align)
371if test "$with_align" = 8 || test "$ac_cv_sizeof_long" = 8; then
372  ac_cv_align=8
373  AC_DEFINE(OM_ALIGN_8,1,"Align to 8 bytes")
374else
375if test "$ac_cv_align_need_strict" = "yes" || test "$with_align" = "strict"; then
376  AC_DEFINE(OM_ALIGNMENT_NEEDS_WORK,1,"Whether alignment needs work")
377  ac_cv_align="strict"
378else
379  ac_cv_align="sloppy"
380fi
381fi
382AC_MSG_RESULT($ac_cv_align)
383
384dnl lllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllll
385dnl dense bins
386dnl
387AC_MSG_CHECKING(whether to use dense bins)
388if test "$with_dense_bins" = yes; then
389AC_MSG_RESULT(yes)
390AC_DEFINE(OM_HAVE_DENSE_BIN_DISTRIBUTION,1,"Whether we have dense bins")
391else
392AC_MSG_RESULT(no)
393fi
394
395dnl lllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllll
396dnl debug and inline
397dnl
398AC_MSG_CHECKING(whether to disable debugging)
399if test "$with_debug" != no; then
400AC_MSG_RESULT(no)
401else
402AC_MSG_RESULT(yes)
403AC_DEFINE(OM_NDEBUG,1,"Disable debug")
404with_track=no
405fi
406
407AC_MSG_CHECKING(whether to have tracking debug functionality)
408if test "$with_track" != no; then
409AC_MSG_RESULT(yes)
410AC_DEFINE(OM_HAVE_TRACK,1,"Have track")
411else
412AC_MSG_RESULT(no)
413fi
414
415AC_MSG_CHECKING(whether to use internal debug)
416if test "$with_internal_debug" = yes; then
417AC_MSG_RESULT(yes)
418AC_DEFINE(OM_INTERNAL_DEBUG,1,"Internal debug")
419with_inline=no
420else
421AC_MSG_RESULT(no)
422fi
423
424AC_MSG_CHECKING(whether to inline)
425if test "$ac_cv_c_inline" != no && test "$with_inline" != no; then
426  AC_DEFINE_UNQUOTED(OM_INLINE, static $ac_cv_c_inline, "inline-declaration")
427  AC_DEFINE_UNQUOTED(OM_INLINE_DECL, static $ac_cv_c_inline, "inline-declaration")
428  AC_DEFINE_UNQUOTED(OM_INLINE_IMPL, static $ac_cv_c_inline, "inline-declaration")
429  AC_DEFINE_UNQUOTED(OM_INLINE_LOCAL, static $ac_cv_c_inline, "inline-declaration")
430  AC_MSG_RESULT(yes)
431else
432  AC_DEFINE_UNQUOTED(OM_INLINE_DECL, extern, "inline-declaration")
433  AC_DEFINE_UNQUOTED(OM_INLINE_IMPL,, "inline-declaration")
434  AC_DEFINE_UNQUOTED(OM_INLINE_LOCAL, static, "inline-declaration")
435  AC_MSG_RESULT(no)
436fi
437
438dnl lllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllll
439dnl backtrace business
440dnl
441AC_MSG_CHECKING(whether GET_RET_ADDR works)
442AC_CACHE_VAL(ac_cv_get_return_addr_works,
443AC_TRY_RUN([
444#include "omReturn.h"
445int test_return_addr()
446{
447  char* f;
448  GET_RET_ADDR(f);
449  return (int) f;
450}
451int main()
452{
453   exit(! test_return_addr());
454}
455], ac_cv_get_return_addr_works=yes,
456   ac_cv_get_return_addr_works=no,
457   ac_cv_get_return_addr_works=no))
458AC_MSG_RESULT($ac_cv_get_return_addr_works)
459if test "$ac_cv_get_return_addr_works" = yes; then
460AC_DEFINE(OM_GET_RETURN_ADDR_WORKS,1, "Whether get return address works")
461fi
462
463AC_MSG_CHECKING(whether omGetBackTrace works)
464AC_CACHE_VAL(ac_cv_get_backtrace_works,
465AC_TRY_RUN([
466#include "omGetBackTrace.c"
467#include <stdio.h>
468int test_backtrace()
469{
470  void* bt;
471  int i = omGetBackTrace(&bt, 0, 10);
472  return i;
473}
474int main()
475{
476   int i;
477   omInitGetBackTrace();
478   i = test_backtrace();
479   if (i == 1) exit(0);
480   else exit(i+1);
481}
482], ac_cv_get_backtrace_works=yes,
483   ac_cv_get_backtrace_works=no,
484   ac_cv_get_backtrace_works=no))
485AC_MSG_RESULT($ac_cv_get_backtrace_works)
486if test "$ac_cv_get_backtrace_works" = yes; then
487AC_DEFINE(OM_GET_BACKTRACE_WORKS,1,"Whether omInitGetBackTrace () works")
488fi
489
490AC_MSG_CHECKING(whether addr2line works)
491AC_CACHE_VAL(ac_cv_prog_addr2line_works,
492AC_TRY_RUN([
493#undef OM_GET_BACKTRACE_WORKS
494#include "omReturn.h"
495#include "omStructs.h"
496#include "omGetBackTrace.h"
497#include "omRet2Info.c"
498#include "omFindExec.c"
499
500
501int test_Ret_2_Info()
502{
503  void* bt;
504  int i;
505  struct omRetInfo_s info;
506
507  GET_RET_ADDR(bt);
508  i = omBackTrace_2_RetInfo(&bt, &info, 1);
509  return i;
510}
511
512int main(int argc, char** argv)
513{
514  int i;
515  omInitRet_2_Info(*argv);
516  i = test_Ret_2_Info();
517  if (i==1) exit(0);
518  else exit (i+10);
519}
520], ac_cv_prog_addr2line_works=yes,
521   ac_cv_prog_addr2line_works=no,
522   ac_cv_prog_addr2line_works=no))
523AC_MSG_RESULT($ac_cv_prog_addr2line_works)
524
525AC_MSG_CHECKING(whether to track return addresses)
526if test "$with_track_return" = no || test "$ac_cv_get_return_addr_works" = no || test "$ac_cv_prog_addr2line_works" != yes; then
527  with_track_return=no
528else
529  AC_DEFINE(OM_TRACK_RETURN,1,"Whether to track return")
530  with_track_return=yes
531fi
532AC_MSG_RESULT($with_track_return)
533
534AC_MSG_CHECKING(whether to track files and line numbers)
535if test "$with_track_fl" = no && test "$with_track_return" = no; then
536  with_track_fl=yes
537fi
538if test "${with_track_fl+set}" != set; then
539  if test "$with_track_return" = yes; then
540    with_track_fl=no
541  else
542    with_track_fl=yes
543  fi
544fi
545AC_MSG_RESULT($with_track_fl)
546if test "$with_track_fl" = yes; then
547  AC_DEFINE(OM_TRACK_FILE_LINE,1,"Whether to track file-line")
548fi
549
550AC_MSG_CHECKING(whether to track stack backtraces)
551if test "$with_track" != no && test "$ac_cv_get_backtrace_works" = yes && test "$with_track_backtrace" != no && test "$ac_cv_prog_addr2line_works" = yes; then
552  with_track_backtrace=yes
553  AC_DEFINE(OM_TRACK_BACKTRACE,1,"Whether to track backtrace")
554else
555  with_track_backtrace=no
556fi
557AC_MSG_RESULT($with_track_backtrace)
558
559AC_MSG_CHECKING(whether to track custom values)
560if test "$with_track" != no && test "$with_track_custom" = yes; then
561  AC_DEFINE(OM_TRACK_CUSTOM,1,"Enable custom tracking")
562else
563  with_track_custom=no
564fi
565AC_MSG_RESULT($with_track_custom)
566
567dnl lllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllll
568dnl figure out the return type of sbrk
569dnl
570
571AC_MSG_CHECKING(return type of sbrk)
572AC_TRY_LINK(
573#define __USE_MISC
574#include <unistd.h>
575,
576void *sbrk();
577,
578AC_DEFINE(Void_t,void,"Type of void"),
579AC_DEFINE(Void_t,char,"Type of void"),
580)
581AC_MSG_RESULT(Void_t)
582
583
584AC_DEFINE(OM_PROVIDE_MALLOC,0,[Provide NO standard routines!])
585
586
587
588dnl lllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllll
589dnl wrap it up
590dnl
591AC_CONFIG_FILES([Makefile])
592AC_OUTPUT
593
Note: See TracBrowser for help on using the repository browser.