From 030a1c5ea67b4d236f3dc31542e51128a8ee0685 Mon Sep 17 00:00:00 2001 From: Eli Zaretskii Date: Mon, 1 Apr 2013 17:35:26 +0300 Subject: [PATCH] Fixed nt/Makefile.in and top-level Makefile.in. Programs in nt/ and lib-src/ compile and link. Warnings and errors in src/. --- Makefile.in | 24 +++++++++++++++++++++--- configure.ac | 3 +++ lib-src/Makefile.in | 5 +++-- nt/Makefile.in | 6 +++--- src/Makefile.in | 3 ++- 5 files changed, 32 insertions(+), 9 deletions(-) diff --git a/Makefile.in b/Makefile.in index 6fbf4699bb8..fc0b2ab4fb0 100644 --- a/Makefile.in +++ b/Makefile.in @@ -274,7 +274,7 @@ EMACS = ${EMACS_NAME}${EXEEXT} EMACSFULL = `echo emacs-${version} | sed '$(TRANSFORM)'`${EXEEXT} # Subdirectories to make recursively. -SUBDIR = lib lib-src src lisp leim $(NTDIR) +SUBDIR = $(NTDIR) lib lib-src src lisp leim # The subdir makefiles created by config.status. SUBDIR_MAKEFILES_IN = @SUBDIR_MAKEFILES_IN@ @@ -317,7 +317,7 @@ epaths-force: FRC -e 's;\(#.*PATH_DOC\).*$$;\1 "${docdir}";') && \ ${srcdir}/build-aux/move-if-change epaths.h.$$$$ src/epaths.h -lib-src src: lib +lib-src src: $(NTDIR) lib src: lib-src FRC @@ -326,7 +326,7 @@ src: lib-src FRC lisp leim: src # These targets should be "${SUBDIR} without `src'". -lib lib-src lisp leim: Makefile FRC +lib lib-src lisp leim nt: Makefile FRC cd $@ && $(MAKE) all $(MFLAGS) \ CC='${CC}' CFLAGS='${CFLAGS}' CPPFLAGS='${CPPFLAGS}' \ LDFLAGS='${LDFLAGS}' MAKE='${MAKE}' @@ -465,6 +465,13 @@ install-arch-dep: src install-arch-indep install-doc ${write_subdir} || exit 1; \ rm -rf ${ns_appresdir}/share; \ fi + if test "x$(NTDIR)" != "x"; then \ + cd $(NTDIR) && \ + $(MAKE) install $(MFLAGS) prefix=${prefix} \ + exec_prefix=${exec_prefix} bindir=${bindir} \ + libexecdir=${libexecdir} archlibdir=${archlibdir} \ + INSTALL_STRIP=${INSTALL_STRIP}; \ + fi ## In the share directory, we are deleting: ## applications (with emacs.desktop, also found in etc/) @@ -695,6 +702,13 @@ uninstall: $(MAKE) $(MFLAGS) uninstall \ prefix=${prefix} exec_prefix=${exec_prefix} \ bindir=${bindir} libexecdir=${libexecdir} archlibdir=${archlibdir} + + if test "x$(NTDIR)" != "x"; then \ + cd $(NTDIR) && \ + $(MAKE) $(MFLAGS) uninstall \ + prefix=${prefix} exec_prefix=${exec_prefix} \ + bindir=${bindir} libexecdir=${libexecdir} archlibdir=${archlibdir}; \ + fi -unset CDPATH; \ for dir in $(DESTDIR)${lispdir} $(DESTDIR)${etcdir} ; do \ if [ -d $${dir} ]; then \ @@ -756,6 +770,7 @@ mostlyclean: FRC (cd lwlib; $(MAKE) $(MFLAGS) mostlyclean) (cd lib; $(MAKE) $(MFLAGS) mostlyclean) (cd lib-src; $(MAKE) $(MFLAGS) mostlyclean) + (cd nt; $(MAKE) $(MFLAGS) mostlyclean) -(cd doc/emacs && $(MAKE) $(MFLAGS) mostlyclean) -(cd doc/misc && $(MAKE) $(MFLAGS) mostlyclean) -(cd doc/lispref && $(MAKE) $(MFLAGS) mostlyclean) @@ -777,6 +792,7 @@ clean: FRC (cd lwlib; $(MAKE) $(MFLAGS) clean) (cd lib; $(MAKE) $(MFLAGS) clean) (cd lib-src; $(MAKE) $(MFLAGS) clean) + (cd nt; $(MAKE) $(MFLAGS) clean) -(cd doc/emacs && $(MAKE) $(MFLAGS) clean) -(cd doc/misc && $(MAKE) $(MFLAGS) clean) -(cd doc/lispref && $(MAKE) $(MFLAGS) clean) @@ -803,6 +819,7 @@ distclean: FRC (cd lwlib; $(MAKE) $(MFLAGS) distclean) (cd lib; $(MAKE) $(MFLAGS) distclean) (cd lib-src; $(MAKE) $(MFLAGS) distclean) + (cd nt; $(MAKE) $(MFLAGS) distclean) (cd doc/emacs && $(MAKE) $(MFLAGS) distclean) (cd doc/misc && $(MAKE) $(MFLAGS) distclean) (cd doc/lispref && $(MAKE) $(MFLAGS) distclean) @@ -821,6 +838,7 @@ bootstrap-clean: FRC (cd lwlib; $(MAKE) $(MFLAGS) maintainer-clean) (cd lib; $(MAKE) $(MFLAGS) maintainer-clean) (cd lib-src; $(MAKE) $(MFLAGS) maintainer-clean) + (cd nt; $(MAKE) $(MFLAGS) maintainer-clean) -(cd doc/emacs && $(MAKE) $(MFLAGS) maintainer-clean) -(cd doc/misc && $(MAKE) $(MFLAGS) maintainer-clean) -(cd doc/lispref && $(MAKE) $(MFLAGS) maintainer-clean) diff --git a/configure.ac b/configure.ac index 919f4934fae..75ecb7bbc96 100644 --- a/configure.ac +++ b/configure.ac @@ -1577,6 +1577,7 @@ if test "${opsys}" = "mingw32"; then fi FIRSTFILE_OBJ= +NTDIR= if test "${HAVE_W32}" = "yes"; then AC_DEFINE(HAVE_NTGUI, 1, [Define to use native MS Windows GUI.]) AC_CHECK_TOOL(WINDRES, [windres], @@ -1601,6 +1602,7 @@ if test "${HAVE_W32}" = "yes"; then CLIENTRES="emacsclient.res" CLIENTW="emacsclientw\$(EXEEXT)" FIRSTFILE_OBJ=firstfile.o + NTDIR=nt fi fi AC_SUBST(W32_OBJ) @@ -1611,6 +1613,7 @@ AC_SUBST(CLIENTRES) AC_SUBST(CLIENTW) AC_SUBST(W32_RES_LINK) AC_SUBST(FIRSTFILE_OBJ) +AC_SUBST(NTDIR) if test "${HAVE_W32}" = "yes"; then window_system=w32 diff --git a/lib-src/Makefile.in b/lib-src/Makefile.in index 3af31acaa6e..c79097695ff 100644 --- a/lib-src/Makefile.in +++ b/lib-src/Makefile.in @@ -365,7 +365,8 @@ update-game-score${EXEEXT}: ${srcdir}/update-game-score.c $(NTLIB) $(config_h) ${srcdir}/update-game-score.c $(NTLIB) $(LOADLIBES) \ -o update-game-score${EXEEXT} -emacsclient.res: ${srcdir}/nt/emacsclient.rc - $(WINDRES) -O coff --include-dir=${srcdir}/nt -o emacscient.res +emacsclient.res: ${srcdir}/../nt/emacsclient.rc + $(WINDRES) -O coff --include-dir=${srcdir}/../nt -o emacsclient.res \ + ${srcdir}/../nt/emacsclient.rc ## Makefile ends here. diff --git a/nt/Makefile.in b/nt/Makefile.in index 3b777047c27..0f7b3463d42 100644 --- a/nt/Makefile.in +++ b/nt/Makefile.in @@ -201,12 +201,12 @@ addpm${EXEEXT}: ${srcdir}/addpm.c ddeclient${EXEEXT}: ${srcdir}/ddeclient.c $(CC) ${ALL_CFLAGS} ${srcdir}/ddeclient.c -o ddeclient${EXEEXT} -cmdproxy{EXEEXT}: ${srcdir}/cmdproxy.c +cmdproxy${EXEEXT}: ${srcdir}/cmdproxy.c $(CC) ${ALL_CFLAGS} ${srcdir}/cmdproxy.c -o cmdproxy${EXEEXT} -runemacs{EXEEXT}: ${srcdir}/runemacs.c $(EMACSRES) +runemacs${EXEEXT}: ${srcdir}/runemacs.c $(EMACSRES) $(CC) ${ALL_CFLAGS} ${srcdir}/runemacs.c $(EMACSRES) \ -o runemacs${EXEEXT} -emacs.res: ${srcdir}/emacs.rc ${srcdir}/emacs.ico ${srcdir}/$(EMACS_MANIFEST) +emacs.res: ${srcdir}/emacs.rc ${srcdir}/icons/emacs.ico ${srcdir}/$(EMACS_MANIFEST) ${WINDRES} -O coff -o emacs.res emacs.rc diff --git a/src/Makefile.in b/src/Makefile.in index cac8ddec57c..62c1e51e298 100644 --- a/src/Makefile.in +++ b/src/Makefile.in @@ -524,7 +524,8 @@ doc.o: buildobj.h emacs.res: $(ntsource)/emacs.rc \ $(ntsource)/icons/emacs.ico \ $(ntsource)/$(EMACS_MANIFEST) - $(WINDRES) -O COFF -o $@ $(ntsource)/emacs.rc + $(WINDRES) -O COFF --include-dir=$(srcdir)/../nt \ + -o $@ $(ntsource)/emacs.rc ns-app: emacs$(EXEEXT) cd ../nextstep && $(MAKE) $(MFLAGS) all -- 2.39.2