2 # uCsim gui.src/Makefile
4 # (c) Drotos Daniel, Talker Bt. 1999
16 DEFS = $(subs -DHAVE_CONFIG_H,,@DEFS@)
17 CPPFLAGS = @CPPFLAGS@ -I. -I$(PRJDIR)
18 CFLAGS = @CFLAGS@ -Wall
19 CXXFLAGS = @CXXFLAGS@ -Wall
22 LIBS = @LIBS@ @CURSES_LIBS@ -L$(PRJDIR)
24 curses_ok = @curses_ok@
27 exec_prefix = @exec_prefix@
31 includedir = @includedir@
33 man1dir = $(mandir)/man1
34 man2dir = $(mandir)/man2
38 PKGS = serio.src portmon.src
41 view.o frame.o bg.o label.o \
42 group.o win.o desk.o app.o
45 # Compiling entire program or any subproject
46 # ------------------------------------------
51 ifeq ($(curses_ok),yes)
52 gui.src: checkconf guilib
54 gui.src: checkconf guilib
56 @for pkg in $(PKGS); do\
57 $(MAKE) -C $$pkg $$pkg ;\
61 $(CXX) $(LDFLAGS) $(LIBS) a.o -o $@
64 # Compiling and installing everything and runing test
65 # ---------------------------------------------------
67 @for pkg in $(PKGS); do\
68 cd $$pkg && $(MAKE) install ; cd ..;\
72 # Deleting all the installed files
73 # --------------------------------
75 @for pkg in $(PKGS); do\
76 cd $$pkg && $(MAKE) uninstall ; cd ..;\
80 # Performing self-test
81 # --------------------
83 @for pkg in $(PKGS); do\
84 cd $$pkg && $(MAKE) check ; cd ..;\
88 # Performing installation test
89 # ----------------------------
91 @for pkg in $(PKGS); do\
92 cd $$pkg && $(MAKE) installcheck ; cd ..;\
96 # Creating installation directories
97 # ---------------------------------
99 @for pkg in $(PKGS); do\
100 cd $$pkg && $(MAKE) installdirs ; cd ..;\
104 # Creating dependencies
105 # ---------------------
108 Makefile.dep: *.cc *.h
109 $(CXXCPP) $(CPPFLAGS) $(M_OR_MM) *.cc >Makefile.dep
120 ifeq ($(curses_ok),yes)
126 libgui.a: $(LOBJECTS)
127 ar -rcu $*.a $(LOBJECTS)
131 $(CXX) $(CXXFLAGS) $(CPPFLAGS) -c $< -o $@
134 # Remaking configuration
135 # ----------------------
137 @if [ -f $(PRJDIR)/devel ]; then\
138 $(MAKE) -f conf.mk srcdir="$(srcdir)" PRJDIR="$(PRJDIR)" freshconf;\
141 # End of gui.src/Makefile