• Skip to sidebar navigation
  • Skip to content

Bitbucket

  • More
    ProjectsRepositories
  • Help
    • Online help
    • Learn Git
    • Welcome to Bitbucket
    • Keyboard shortcuts
  • Log In
Alexander Dahl
  1. Alexander Dahl

buildroot

Public
Actions
  • Clone
  • Compare

Learn more about cloning repositories

You have read-only access

Navigation
  • Source
  • Commits
  • Branches
  • All Branches Graph
  • Forks
  1. Alexander Dahl
  2. buildroot

Source

buildroot/package/libsrtp/0001-Add-support-for-building-on-cross-compiling-the-shar.patch
Thomas PetazzoniThomas Petazzoni committed 1b12b7e818901 Jan 2015
Raw file
Source viewDiff to previous
xxxxxxxxxx
    if [ "$(srcdir)" != "." ]; then cp crypto/include/*.h $(DESTDIR)$(includedir)/srtp; fi
 
1
From 8e1dadbcb7ec6be1c568550e97a9e3ce565758bf Mon Sep 17 00:00:00 2001
2
From: Nirbheek Chauhan <nirbheek@centricular.com>
3
Date: Wed, 5 Nov 2014 18:35:14 +0530
4
Subject: [PATCH] Add support for building on/cross-compiling the shared
5
 library for Windows and OS X
6
​
7
Also ensure that the shared library is versioned, and an implib is created on
8
Windows.
9
​
10
Commit backported from upstream.
11
​
12
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
13
---
14
 Makefile.in | 53 ++++++++++++++++++++++++++++++++++++++++-------------
15
 1 file changed, 40 insertions(+), 13 deletions(-)
16
​
17
diff --git a/Makefile.in b/Makefile.in
18
index 5a7fc21..5ca4453 100644
19
--- a/Makefile.in
20
+++ b/Makefile.in
21
@@ -17,7 +17,7 @@
22
 USE_OPENSSL = @USE_OPENSSL@
23
 HAVE_PKG_CONFIG = @HAVE_PKG_CONFIG@
24
 
25
-.PHONY: all test build_table_apps
26
+.PHONY: all shared_library test build_table_apps
27
 
28
 all: test 
29
 
30
@@ -43,10 +43,10 @@ endif
31
 CC = @CC@
32
 INCDIR = -Icrypto/include -I$(srcdir)/include -I$(srcdir)/crypto/include
33
 DEFS   = @DEFS@
34
-CPPFLAGS= @CPPFLAGS@
35
+CPPFLAGS= -fPIC @CPPFLAGS@
36
 CFLAGS = @CFLAGS@
37
 LIBS   = @LIBS@
38
-LDFLAGS    = @LDFLAGS@ -L.
39
+LDFLAGS    = -L. @LDFLAGS@
40
 COMPILE = $(CC) $(DEFS) $(INCDIR) $(CPPFLAGS) $(CFLAGS)
41
 SRTPLIB    = -lsrtp
42
 
43
@@ -75,12 +75,33 @@ prefix = @prefix@
44
 exec_prefix = @exec_prefix@
45
 includedir = @includedir@
46
 libdir = @libdir@
47
+bindir = @bindir@
48
 
49
 ifeq (1, $(HAVE_PKG_CONFIG))
50
 pkgconfigdir = $(libdir)/pkgconfig
51
 pkgconfig_DATA = libsrtp.pc
52
 endif
53
 
54
+SHAREDLIBVERSION = 1
55
+ifeq (linux,$(findstring linux,@host@))
56
+SHAREDLIB_DIR = $(libdir)
57
+SHAREDLIB_LDFLAGS = -shared -Wl,-soname,$@
58
+SHAREDLIBSUFFIXNOVER = so
59
+SHAREDLIBSUFFIX = $(SHAREDLIBSUFFIXNOVER).$(SHAREDLIBVERSION)
60
+else ifeq (mingw,$(findstring mingw,@host@))
61
+SHAREDLIB_DIR = $(bindir)
62
+SHAREDLIB_LDFLAGS = -shared -Wl,--out-implib,libsrtp.dll.a
63
+SHAREDLIBVERSION =
  • Git repository management for enterprise teams powered by Atlassian Bitbucket
  • Atlassian Bitbucket v6.7.2
  • Documentation
  • Request a feature
  • About
  • Contact Atlassian
Atlassian

Everything looks good. We'll let you know here if there's anything you should know about.