js/src/shell/Makefile.in
author Mike Hommey <mh+mozilla@glandium.org>
Thu, 12 Jul 2012 08:30:59 +0200
changeset 103852 4be97839a566d8f482f431801237afc4caac22ae
parent 103285 d64dfd57d873158c6aab632032b3cc776b521540
child 106884 2ef51674316aadfe26a46877b16794f758bf4b6d
permissions -rw-r--r--
Bug 763651 - Link the javascript engine against zlib. r=khuey

# -*- Mode: makefile -*-
#
# This Source Code Form is subject to the terms of the Mozilla Public
# License, v. 2.0. If a copy of the MPL was not distributed with this
# file, You can obtain one at http://mozilla.org/MPL/2.0/.

DEPTH		= ..
topsrcdir	= @top_srcdir@
srcdir		= @srcdir@
VPATH		= @srcdir@

include $(DEPTH)/config/autoconf.mk

PROGRAM         = js$(BIN_SUFFIX)
CPPSRCS		= \
  js.cpp \
  jsoptparse.cpp \
  jsheaptools.cpp \
  $(NULL)

DEFINES         += -DEXPORT_JS_API
# Building against js_static requires that we declare mfbt sybols "exported"
# on its behalf.
DEFINES         += -DIMPL_MFBT

LIBS      = $(NSPR_LIBS) $(EDITLINE_LIBS) $(DEPTH)/$(LIB_PREFIX)js_static.$(LIB_SUFFIX) $(MOZ_ZLIB_LIBS)
ifdef MOZ_NATIVE_FFI
EXTRA_LIBS += $(MOZ_FFI_LIBS)
endif

LOCAL_INCLUDES += -I$(topsrcdir) -I..

ifeq ($(OS_ARCH),Darwin)
ifeq ($(TARGET_CPU),x86_64)
DARWIN_EXE_LDFLAGS += -pagezero_size 10000 -image_base 100000000
endif
endif

include $(topsrcdir)/config/rules.mk

ifdef MOZ_SHARK
CFLAGS += -F/System/Library/PrivateFrameworks
CXXFLAGS += -F/System/Library/PrivateFrameworks
LDFLAGS += -F/System/Library/PrivateFrameworks -framework CHUD
endif

# People expect the js shell to wind up in the top-level JS dir.
libs::
	$(INSTALL) $(IFLAGS2) $(PROGRAM) $(DEPTH)

GARBAGE += $(DEPTH)/$(PROGRAM)

install:: $(PROGRAM)
	$(SYSINSTALL) $^ $(DESTDIR)$(bindir)