~ubuntu-branches/ubuntu/trusty/erlang/trusty

« back to all changes in this revision

Viewing changes to lib/asn1/c_src/Makefile

  • Committer: Bazaar Package Importer
  • Author(s): Clint Byrum
  • Date: 2011-05-05 15:48:43 UTC
  • mfrom: (3.5.13 sid)
  • Revision ID: james.westby@ubuntu.com-20110505154843-0om6ekzg6m7ugj27
Tags: 1:14.b.2-dfsg-3ubuntu1
* Merge from debian unstable.  Remaining changes:
  - Drop libwxgtk2.8-dev build dependency. Wx isn't in main, and not
    supposed to.
  - Drop erlang-wx binary.
  - Drop erlang-wx dependency from -megaco, -common-test, and -reltool, they
    do not really need wx. Also drop it from -debugger; the GUI needs wx,
    but it apparently has CLI bits as well, and is also needed by -megaco,
    so let's keep the package for now.
  - debian/patches/series: Do what I meant, and enable build-options.patch
    instead.
* Additional changes:
  - Drop erlang-wx from -et
* Dropped Changes:
  - patches/pcre-crash.patch: CVE-2008-2371: outer level option with
    alternatives caused crash. (Applied Upstream)
  - fix for ssl certificate verification in newSSL: 
    ssl_cacertfile_fix.patch (Applied Upstream)
  - debian/patches/series: Enable native.patch again, to get stripped beam
    files and reduce the package size again. (build-options is what
    actually accomplished this)
  - Remove build-options.patch on advice from upstream and because it caused
    odd build failures.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
1
#
2
2
# %CopyrightBegin%
3
 
4
 
# Copyright Ericsson AB 2002-2009. All Rights Reserved.
5
 
 
3
#
 
4
# Copyright Ericsson AB 2002-2010. All Rights Reserved.
 
5
#
6
6
# The contents of this file are subject to the Erlang Public License,
7
7
# Version 1.1, (the "License"); you may not use this file except in
8
8
# compliance with the License. You should have received a copy of the
9
9
# Erlang Public License along with this software. If not, it can be
10
10
# retrieved online at http://www.erlang.org/.
11
 
 
11
#
12
12
# Software distributed under the License is distributed on an "AS IS"
13
13
# basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See
14
14
# the License for the specific language governing rights and limitations
15
15
# under the License.
16
 
 
16
#
17
17
# %CopyrightEnd%
18
18
#
19
19
#
20
 
include $(ERL_TOP)/make/run_make.mk
 
20
include $(ERL_TOP)/make/target.mk
 
21
include $(ERL_TOP)/make/$(TARGET)/otp.mk
 
22
include $(ERL_TOP)/make/$(TARGET)/otp_ded.mk
 
23
 
 
24
CC = $(DED_CC)
 
25
LD = $(DED_LD)
 
26
LIBS = $(DED_LIBS)
 
27
 
 
28
# ----------------------------------------------------
 
29
# Application version
 
30
# ----------------------------------------------------
 
31
include ../vsn.mk
 
32
VSN=$(ASN1_VSN)
 
33
 
 
34
# ----------------------------------------------------
 
35
# Release directory specification
 
36
# ----------------------------------------------------
 
37
RELSYSDIR = $(RELEASE_PATH)/lib/asn1-$(VSN)
 
38
 
 
39
 
 
40
# ----------------------------------------------------
 
41
# FLAGS misc
 
42
# ----------------------------------------------------
 
43
ifeq ($(TYPE),debug)
 
44
TYPEMARKER = .debug
 
45
else
 
46
TYPEMARKER =
 
47
endif
 
48
 
 
49
EI_LIBDIR = $(ERL_TOP)/lib/erl_interface/obj$(TYPEMARKER)/$(TARGET)
 
50
 
 
51
# ----------------------------------------------------
 
52
# FLAGS
 
53
# ----------------------------------------------------
 
54
EI_INCLUDES = -I$(ERL_TOP)/lib/erl_interface/include
 
55
CFLAGS = $(DED_INCLUDES) $(EI_INCLUDES) $(DED_CFLAGS)
 
56
LDFLAGS += $(DED_LDFLAGS)
 
57
 
 
58
LD_INCL_EI = -L$(EI_LIBDIR)
 
59
 
 
60
# ----------------------------------------------------
 
61
# Target Specs
 
62
# ----------------------------------------------------
 
63
 
 
64
C_FILES = asn1_erl_driver.c
 
65
 
 
66
 
 
67
ifeq ($(TARGET),win32)
 
68
LD_EI = -lei_md 
 
69
SHARED_OBJ_FILES = $(LIBDIR)/asn1_erl_drv.dll
 
70
OBJ_FILES = $(OBJDIR)/asn1_erl_drv.o
 
71
CLIB_FLAGS =
 
72
LN=cp
 
73
else
 
74
LD_EI = -lei 
 
75
OBJ_FILES = $(OBJDIR)/asn1_erl_drv.o
 
76
ifeq ($(findstring vxworks,$(TARGET)),vxworks)
 
77
SHARED_OBJ_FILES = $(LIBDIR)/asn1_erl_drv.eld
 
78
CLIB_FLAGS =
 
79
else
 
80
SHARED_OBJ_FILES = $(LIBDIR)/asn1_erl_drv.so
 
81
CLIB_FLAGS = -lc
 
82
endif
 
83
LN= ln -s
 
84
endif
 
85
 
 
86
# ----------------------------------------------------
 
87
# Targets
 
88
# ----------------------------------------------------
 
89
 
 
90
opt: $(OBJDIR) $(LIBDIR) $(SHARED_OBJ_FILES)
 
91
 
 
92
debug: opt
 
93
 
 
94
clean:
 
95
        rm -f core *~ 
 
96
        rm -f $(LIBDIR)/*
 
97
        rm -f $(OBJDIR)/*
 
98
 
 
99
docs:
 
100
 
 
101
# ----------------------------------------------------
 
102
# Special Build Targets
 
103
# ----------------------------------------------------
 
104
 
 
105
 
 
106
$(OBJ_FILES): $(C_FILES)
 
107
        $(CC) -c $(CFLAGS) -o $(OBJ_FILES) $(C_FILES) 
 
108
 
 
109
$(SHARED_OBJ_FILES): $(OBJ_FILES)
 
110
        $(LD) $(LDFLAGS) $(LD_INCL_EI) -o $(SHARED_OBJ_FILES) $(OBJ_FILES) $(LD_EI) $(CLIB_FLAGS) $(LIBS) 
 
111
 
 
112
$(LIBDIR):
 
113
        -mkdir -p $(LIBDIR)
 
114
 
 
115
$(OBJDIR):
 
116
        -mkdir -p $(OBJDIR)
 
117
 
 
118
 
 
119
 
 
120
# ----------------------------------------------------
 
121
# Release Target
 
122
# ----------------------------------------------------
 
123
include $(ERL_TOP)/make/otp_release_targets.mk
 
124
 
 
125
release_spec: opt
 
126
        $(INSTALL_DIR) $(RELSYSDIR)/priv/lib
 
127
        $(INSTALL_PROGRAM) $(SHARED_OBJ_FILES) $(RELSYSDIR)/priv/lib
 
128
        $(INSTALL_DIR) $(RELSYSDIR)/c_src
 
129
        $(INSTALL_DATA) $(C_FILES) $(RELSYSDIR)/c_src
 
130
 
 
131
release_docs_spec:
 
132