source: git/omalloc/configure.ac @ 8291be

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