annotate src/readline.mk @ 3122:c2864508b524

[MSVC] enable readline compilation
author Michael Goffioul <michael.goffioul@gmail.com>
date Fri, 05 Jul 2013 22:25:41 -0400
parents 5ef49fb3299d
children cf6f40cededb
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
2333
f653602a0500 Rebrand to new project name MXE
Volker Grabsch <vog@notjusthosting.com>
parents: 1588
diff changeset
1 # This file is part of MXE.
2353
99516e73b368 Move doc/index.html -> index.html
Volker Grabsch <vog@notjusthosting.com>
parents: 2349
diff changeset
2 # See index.html for further information.
414
d2a6561bcb6d add a copyright notice and license to each source file
Volker Grabsch <vog@notjusthosting.com>
parents: 332
diff changeset
3
330
67fb15f9072f new package: readline
Volker Grabsch <vog@notjusthosting.com>
parents:
diff changeset
4 PKG := readline
448
e9afec55fd6b improved version recognition, enable the notation of ignored (bad) package versions
Volker Grabsch <vog@notjusthosting.com>
parents: 417
diff changeset
5 $(PKG)_IGNORE :=
1588
9f84b0698dcd update package readline
Mark Brand <mabrand@mabrand.nl>
parents: 759
diff changeset
6 $(PKG)_CHECKSUM := a9761cd9c3da485eb354175fcc2fe35856bc43ac
330
67fb15f9072f new package: readline
Volker Grabsch <vog@notjusthosting.com>
parents:
diff changeset
7 $(PKG)_SUBDIR := readline-$($(PKG)_VERSION)
67fb15f9072f new package: readline
Volker Grabsch <vog@notjusthosting.com>
parents:
diff changeset
8 $(PKG)_FILE := readline-$($(PKG)_VERSION).tar.gz
67fb15f9072f new package: readline
Volker Grabsch <vog@notjusthosting.com>
parents:
diff changeset
9 $(PKG)_URL := http://ftp.gnu.org/gnu/readline/$($(PKG)_FILE)
2997
4f9b72cf7ee7 allow native builds too
John W. Eaton <jwe@octave.org>
parents: 2904
diff changeset
10
3038
b39961d2ce59 readline: use termcap for mingw native or cross builds
John W. Eaton <jwe@octave.org>
parents: 3013
diff changeset
11 ifeq ($(MXE_SYSTEM),mingw)
b39961d2ce59 readline: use termcap for mingw native or cross builds
John W. Eaton <jwe@octave.org>
parents: 3013
diff changeset
12 $(PKG)_TERMCAP_LIB := termcap
2997
4f9b72cf7ee7 allow native builds too
John W. Eaton <jwe@octave.org>
parents: 2904
diff changeset
13 else
3038
b39961d2ce59 readline: use termcap for mingw native or cross builds
John W. Eaton <jwe@octave.org>
parents: 3013
diff changeset
14 $(PKG)_TERMCAP_LIB := ncurses
2997
4f9b72cf7ee7 allow native builds too
John W. Eaton <jwe@octave.org>
parents: 2904
diff changeset
15 endif
4f9b72cf7ee7 allow native builds too
John W. Eaton <jwe@octave.org>
parents: 2904
diff changeset
16
3048
5ef49fb3299d treat gcc and binutils as build tools
John W. Eaton <jwe@octave.org>
parents: 3038
diff changeset
17 $(PKG)_DEPS := $($(PKG)_TERMCAP_LIB)
330
67fb15f9072f new package: readline
Volker Grabsch <vog@notjusthosting.com>
parents:
diff changeset
18
67fb15f9072f new package: readline
Volker Grabsch <vog@notjusthosting.com>
parents:
diff changeset
19 define $(PKG)_UPDATE
2525
4d0f3a9da57e all packages: use $(WGET) portability variable
Tony Theodore <tonyt@logyst.com>
parents: 2365
diff changeset
20 $(WGET) -q -O- 'http://tiswww.case.edu/php/chet/readline/rltop.html' | \
330
67fb15f9072f new package: readline
Volker Grabsch <vog@notjusthosting.com>
parents:
diff changeset
21 grep 'readline-' | \
67fb15f9072f new package: readline
Volker Grabsch <vog@notjusthosting.com>
parents:
diff changeset
22 $(SED) -n 's,.*readline-\([0-9][^>]*\)\.tar.*,\1,p' | \
67fb15f9072f new package: readline
Volker Grabsch <vog@notjusthosting.com>
parents:
diff changeset
23 head -1
67fb15f9072f new package: readline
Volker Grabsch <vog@notjusthosting.com>
parents:
diff changeset
24 endef
67fb15f9072f new package: readline
Volker Grabsch <vog@notjusthosting.com>
parents:
diff changeset
25
67fb15f9072f new package: readline
Volker Grabsch <vog@notjusthosting.com>
parents:
diff changeset
26 define $(PKG)_BUILD
759
bf4bcb3370fa changed coding style: make "-i" always the first argument of $(SED) (by Mark Brand)
Volker Grabsch <vog@notjusthosting.com>
parents: 714
diff changeset
27 $(SED) -i 's,^ *case SIGQUIT:.*,,' '$(1)/signals.c'
bf4bcb3370fa changed coding style: make "-i" always the first argument of $(SED) (by Mark Brand)
Volker Grabsch <vog@notjusthosting.com>
parents: 714
diff changeset
28 $(SED) -i 's,^ *case SIGTSTP:.*,,' '$(1)/signals.c'
3122
c2864508b524 [MSVC] enable readline compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents: 3048
diff changeset
29 if test x$(MXE_SYSTEM) = xmsvc; then \
c2864508b524 [MSVC] enable readline compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents: 3048
diff changeset
30 for f in '$(1)/support/shlib-install' '$(1)/support/shobj-conf'; do \
c2864508b524 [MSVC] enable readline compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents: 3048
diff changeset
31 $(SED) -i -e 's/@@LIBRARY_PREFIX@@/$(LIBRARY_PREFIX)/g' \
c2864508b524 [MSVC] enable readline compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents: 3048
diff changeset
32 -e 's/@@LIBRARY_SUFFIX@@/$(LIBRARY_SUFFIX)/g' $$f; \
c2864508b524 [MSVC] enable readline compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents: 3048
diff changeset
33 done; \
c2864508b524 [MSVC] enable readline compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents: 3048
diff changeset
34 fi
330
67fb15f9072f new package: readline
Volker Grabsch <vog@notjusthosting.com>
parents:
diff changeset
35 cd '$(1)' && ./configure \
2997
4f9b72cf7ee7 allow native builds too
John W. Eaton <jwe@octave.org>
parents: 2904
diff changeset
36 $(CONFIGURE_CPPFLAGS) $(CONFIGURE_LDFLAGS) \
3013
bcc26ffe9a0f use variable for --host and --build configure arguments
John W. Eaton <jwe@octave.org>
parents: 3012
diff changeset
37 $(HOST_AND_BUILD_CONFIGURE_OPTIONS) \
2855
47558e958113 Allow static/shared libraries to be configured in top-level Makefile.
John W. Eaton <jwe@octave.org>
parents: 2525
diff changeset
38 $(ENABLE_SHARED_OR_STATIC) \
3012
100e618349f7 Improve handling of prefix directories by defining HOST_PREFIX and
John W. Eaton <jwe@octave.org>
parents: 2997
diff changeset
39 --prefix='$(HOST_PREFIX)' \
332
0eb8062e5797 enable multibyte characters in package readline
Volker Grabsch <vog@notjusthosting.com>
parents: 331
diff changeset
40 --enable-multibyte \
2904
1122ae1e98b6 New rules for termcap package.
John W. Eaton <jwe@octave.org>
parents: 2864
diff changeset
41 --without-purify
2855
47558e958113 Allow static/shared libraries to be configured in top-level Makefile.
John W. Eaton <jwe@octave.org>
parents: 2525
diff changeset
42 $(MAKE) -C '$(1)' -j '$(JOBS)' install
330
67fb15f9072f new package: readline
Volker Grabsch <vog@notjusthosting.com>
parents:
diff changeset
43 endef