mirror of
https://github.com/Mercury-Language/mercury.git
synced 2026-04-18 02:43:40 +00:00
Estimated hours taken: 0.25 util/mkinit.c: util/Mmakefile: Fix another file renaming induced problem: s/getopt.h/mercury_getopt.h/g
48 lines
1.4 KiB
Plaintext
48 lines
1.4 KiB
Plaintext
#-----------------------------------------------------------------------------#
|
|
# Copyright (C) 1995-1997 The University of Melbourne.
|
|
# This file may only be copied under the terms of the GNU General
|
|
# Public License - see the file COPYING in the Mercury distribution.
|
|
#-----------------------------------------------------------------------------#
|
|
|
|
# Mmake - Mmake file for the Mercury utilities directory
|
|
|
|
MAIN_TARGET=all
|
|
|
|
#-----------------------------------------------------------------------------#
|
|
|
|
MERCURY_DIR=..
|
|
include $(MERCURY_DIR)/Mmake.common
|
|
|
|
#-----------------------------------------------------------------------------#
|
|
|
|
MGNUC = MERCURY_C_INCL_DIR=$(RUNTIME_DIR) $(SCRIPTS_DIR)/mgnuc
|
|
CFLAGS = -I$(RUNTIME_DIR) $(EXTRA_CFLAGS)
|
|
# we need -I ../runtime for "mercury_getopt.h"
|
|
|
|
PROGS=mkinit mdemangle
|
|
|
|
#-----------------------------------------------------------------------------#
|
|
|
|
all: $(PROGS)
|
|
|
|
.c:
|
|
$(MGNUC) --grade $(GRADE) $(CFLAGS) -o $@ $<
|
|
|
|
#-----------------------------------------------------------------------------#
|
|
|
|
.PHONY: install
|
|
install: $(PROGS)
|
|
[ -d $(INSTALL_BINDIR) ] || mkdir -p $(INSTALL_BINDIR)
|
|
cp `vpath_find $(PROGS)` $(INSTALL_BINDIR)
|
|
|
|
.PHONY: uninstall
|
|
uninstall:
|
|
-cd $(INSTALL_BINDIR) && rm $(PROGS)
|
|
|
|
#-----------------------------------------------------------------------------#
|
|
|
|
realclean:
|
|
-rm -f $(PROGS)
|
|
|
|
#-----------------------------------------------------------------------------#
|