Buildchain fixes and updates from Sebastian
[sxemacs] / src / ui / Makefile.am
1 ## SXEmacs - Ent Makefile.am
2
3 ## Copyright (C) 2010 Steve Youngs
4
5 ## This file is part of SXEmacs.
6
7 ## SXEmacs is free software: you can redistribute it and/or modify
8 ## it under the terms of the GNU General Public License as published by
9 ## the Free Software Foundation, either version 3 of the License, or
10 ## (at your option) any later version.
11
12 ## SXEmacs is distributed in the hope that it will be useful,
13 ## but WITHOUT ANY WARRANTY; without even the implied warranty of
14 ## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
15 ## GNU General Public License for more details.
16
17 ## You should have received a copy of the GNU General Public License
18 ## along with this program.  If not, see <http://www.gnu.org/licenses/>.
19
20 ## Process this file with automake to produce Makefile.in
21
22 # Help the Developers and yourself. Just use the C locale and settings
23 # for the compilation. They can still be overriden by make LANG=<whatever>
24 # but that is general a not very good idea
25 LANG=C
26 LC_ALL=C
27
28 builddir = @builddir@
29 srcdir = @srcdir@
30 top_builddir = @top_builddir@
31 top_build_prefix = $(top_builddir)/
32 top_srcdir = @top_srcdir@
33 abs_builddir = @abs_builddir@
34 abs_top_builddir = @abs_top_builddir@
35 abs_top_srcdir = @abs_top_srcdir@
36 sxelibsrcdir = $(abs_top_srcdir)/lib-src
37
38 AM_CFLAGS = -Demacs $(OPENSSL_CFLAGS) -DUSE_SXEMACS_CONFIG_H -DXTSTRINGDEFINES
39 AM_CPPFLAGS = -I$(srcdir) -I$(builddir) -I$(top_srcdir)/src -I$(top_builddir)/src -I$(top_builddir) $(c_switch_general) $(LTDLINCL)
40
41 headerdir = $(includedir)/$(instvarsepdir)
42 archlibdir = ${libdir}/${instvardir}/${configuration}
43
44
45 ETAGS = $(top_builddir)/lib-src/etags
46 TAGS_DEPENDENCIES = $(ETAGS)
47
48 SUBDIRS=
49 all_sources=
50 noinst_LIBRARIES=
51 header_HEADERS=$(acgen_headers) 
52
53 BUILT_SOURCES = Emacs.ad.h
54 EXTRA_DIST = Emacs.ad.h 
55
56 libsxeui_a_headers =                               \
57         Emacs.ad.h  bitmaps.h                      \
58         conslots.h console-stream.h                \
59         console.h device.h faces.h frame.h         \
60         frameslots.h getpagesize.h gifrlib.h       \
61         glyphs.h gui.h gutter.h                    \
62         imgproc.h insdel.h keymap.h menubar.h      \
63         objects.h redisplay.h scrollbar.h select.h \
64         toolbar.h universe.h window.h winslots.h                      
65 libsxeui_a_sources =                                                    \
66         console.c console-stream.c device.c faces.c font-lock.c         \
67         frame.c glyphs.c glyphs-eimage.c glyphs-widget.c gui.c gutter.c \
68         imgproc.c keymap.c insdel.c minibuf.c redisplay.c               \
69         redisplay-output.c select.c specifier.c widget.c window.c 
70 libsxeui_a_SOURCES = $(libsxeui_a_headers) $(libsxeui_a_sources)
71 libsxeui_a_CPPFLAGS = $(AM_CPPFLAGS) $(c_switch_general) $(X_CFLAGS)
72 EXTRA_libsxeui_a_SOURCES=scrollbar.c menubar.c dialog.c toolbar.c
73 libsxeui_a_LIBADD = $(libsxeui_objs)
74 libsxeui_a_DEPENDENCIES = $(libsxeui_objs)
75 all_sources += $(libsxeui_a_sources) $(libsxeui_objs:.o=.c)
76
77 header_HEADERS += $(libsxeui_a_headers)
78 noinst_LIBRARIES += libsxeui.a
79
80 if NEED_LIBSXEUITTY
81 SUBDIRS+=TTY
82 endif
83
84 if DESCEND_LWLIB
85 SUBDIRS+=lwlib
86 endif
87
88 if NEED_LIBSXEUIX11
89 SUBDIRS+=X11
90 endif
91
92 if NEED_LIBSXEUIGTK
93 SUBDIRS+=Gtk
94 endif
95
96 Emacs.ad.h: $(top_srcdir)/etc/Emacs.ad
97         @echo "Producing \`src/Emacs.ad.h' from \`etc/Emacs.ad'."
98         @(echo "/*      Do not edit this file!" ; \
99           echo "        Automatically generated from $(top_srcdir)/etc/Emacs.ad" ; \
100           echo " */" ; \
101           $(SHELL) $(sxelibsrcdir)/ad2c $(top_srcdir)/etc/Emacs.ad ) > $@
102
103
104 # Help the SXEmacs developers get nice post-processed source files
105
106 ## Create preprocessor output (debugging purposes only)
107 .c.i:
108         $(COMPILE) -E -o $@ $<
109
110 ## Create assembler output (debugging purposes only)
111 .c.s:
112         $(COMPILE) -S -c $(cflags) $<