Use configure's endian checks to determine whether to set LSB in il/.
Add locale.h check, include to Helpos.c
Both via including autotools_config.h.
****************************************************************************
************************************<+>*************************************/
-
#include <sys/param.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
+
+#include <autotools_config.h>
+#if defined(HAVE_LOCALE_H)
+#include <locale.h>
+#endif
+
#define X_INCLUDE_PWD_H
#define XOS_USE_XT_LOCKING
#include <X11/Xos_r.h>
libDtHelp_la_CFLAGS = -I./il -I./jpeg -I../DtSvc/DtUtil2 -DDTLIB \
-DCDE_INSTALLATION_TOP='"${prefix}"' \
- -DCDE_CONFIGURATION_TOP='"$(CDE_CONFIGURATION_TOP)"'
+ -DCDE_CONFIGURATION_TOP='"$(CDE_CONFIGURATION_TOP)"' \
+ @DT_INCDIR@ @DTI_INCDIR@
libDtHelp_la_LIBADD = -ljpeg il/libil.la
noinst_LTLIBRARIES = libil.la
libil_la_CFLAGS = -I.. -DDTLIB -DCDE_INSTALLATION_TOP='"${prefix}"' \
- -DCDE_CONFIGURATION_TOP='"$(CDE_CONFIGURATION_TOP)"'
-
-if BSD
-libil_la_CFLAGS += -DLSB_BIT_ORDER
-else
- if LINUX
- libil_la_CFLAGS += -DLSB_BIT_ORDER
- else
- if SUN
- libil_la_CFLAGS += -DLSB_BIT_ORDER
- endif
- endif
-endif
+ -DCDE_CONFIGURATION_TOP='"$(CDE_CONFIGURATION_TOP)"' \
+ @DT_INCDIR@ @DTI_INCDIR@
libil_la_SOURCES = ilX.c ilbigray.c ilcodec.c \
ilcontext.c ilconvert.c ilcrop.c \
/* General internal definitions for Image Library (IL).
*/
+/* use autotools detection to determine endianess */
+#include <autotools_config.h>
+#ifndef WORDS_BIGENDIAN
+# define LSB_BIT_ORDER
+#endif
+
#include <stddef.h> /* for size_t declaration */
#ifndef IL_H
#include "il.h"