commit:     23bd0520d401ac1d8743d25666504184354c1bf5
Author:     Justin Lecher <jlec <AT> gentoo <DOT> org>
AuthorDate: Mon May 25 08:29:00 2015 +0000
Commit:     Justin Lecher <jlec <AT> gentoo <DOT> org>
CommitDate: Tue May 26 08:09:50 2015 +0000
URL:        https://gitweb.gentoo.org/proj/sci.git/commit/?id=23bd0520

dev-libs/utf8proc: Fix build process, 
https://github.com/gentoo-science/sci/issues/427

Package-Manager: portage-2.2.20

 dev-libs/utf8proc/ChangeLog                        |  7 ++++
 .../utf8proc/files/utf8proc-1.2-buildflags.patch   | 40 ++++++++++++++++++----
 dev-libs/utf8proc/metadata.xml                     |  4 +--
 ...{utf8proc-1.2.ebuild => utf8proc-1.2-r1.ebuild} | 13 ++++---
 4 files changed, 51 insertions(+), 13 deletions(-)

diff --git a/dev-libs/utf8proc/ChangeLog b/dev-libs/utf8proc/ChangeLog
index f822d34..77d9155 100644
--- a/dev-libs/utf8proc/ChangeLog
+++ b/dev-libs/utf8proc/ChangeLog
@@ -2,6 +2,13 @@
 # Copyright 1999-2015 Gentoo Foundation; Distributed under the GPL v2
 # $Header: $
 
+*utf8proc-1.2-r1 (25 May 2015)
+
+  25 May 2015; Justin Lecher <[email protected]> +utf8proc-1.2-r1.ebuild,
+  -utf8proc-1.2.ebuild, files/utf8proc-1.2-buildflags.patch, metadata.xml:
+  dev-libs/utf8proc: Fix build process, https://github.com/gentoo-
+  science/sci/issues/427
+
 *utf8proc-1.2 (21 May 2015)
 
   21 May 2015; Marius Brehler <[email protected]>

diff --git a/dev-libs/utf8proc/files/utf8proc-1.2-buildflags.patch 
b/dev-libs/utf8proc/files/utf8proc-1.2-buildflags.patch
index 4d583e4..de8847c 100644
--- a/dev-libs/utf8proc/files/utf8proc-1.2-buildflags.patch
+++ b/dev-libs/utf8proc/files/utf8proc-1.2-buildflags.patch
@@ -1,14 +1,40 @@
-Adjust build flags. Proted from 1.1.6.
+ Makefile | 9 +++++----
+ 1 file changed, 5 insertions(+), 4 deletions(-)
 
-Patch by Marius Brehler.
---- Makefile
-+++ Makefile
-@@ -6,7 +6,7 @@ AR=ar
+diff --git a/Makefile b/Makefile
+index aba2453..5fab07d 100644
+--- a/Makefile
++++ b/Makefile
+@@ -6,8 +6,8 @@ AR=ar
  INSTALL=install
  
  # compiler settings
 -cflags = -O2 -std=c99 -pedantic -Wall -fpic -DUTF8PROC_EXPORTS $(CFLAGS)
-+cflags = -std=c99 -pedantic -fpic -DUTF8PROC_EXPORTS $(CFLAGS)
- cc = $(CC) $(cflags)
+-cc = $(CC) $(cflags)
++CFLAGS ?= -O2
++CFLAGS += -std=c99 -pedantic -Wall -fpic -DUTF8PROC_EXPORTS
  
  # shared-library version MAJOR.MINOR.PATCH ... this may be *different*
+ # from the utf8proc version number because it indicates ABI compatibility,
+@@ -54,18 +54,19 @@ data/utf8proc_data.c.new: libutf8proc.$(SHLIB_EXT) 
data/data_generator.rb data/c
+       $(MAKE) -C data utf8proc_data.c.new
+ 
+ utf8proc.o: utf8proc.h utf8proc.c utf8proc_data.c
+-      $(cc) -c -o utf8proc.o utf8proc.c
++      $(CC) $(CFLAGS) -c -o utf8proc.o utf8proc.c
+ 
+ libutf8proc.a: utf8proc.o
+       rm -f libutf8proc.a
+       $(AR) rs libutf8proc.a utf8proc.o
+ 
+ libutf8proc.so.$(MAJOR).$(MINOR).$(PATCH): utf8proc.o
+-      $(cc) -shared -o $@ -Wl,-soname -Wl,libutf8proc.so.$(MAJOR) utf8proc.o
++      $(CC) $(LDFLAGS) -shared -o $@ -Wl,-soname -Wl,libutf8proc.so.$(MAJOR) 
utf8proc.o
+       chmod a-x $@
+ 
+ libutf8proc.so: libutf8proc.so.$(MAJOR).$(MINOR).$(PATCH)
+       ln -f -s libutf8proc.so.$(MAJOR).$(MINOR).$(PATCH) $@
++      ln -f -s libutf8proc.so.$(MAJOR).$(MINOR).$(PATCH) $@.$(MAJOR)
+ 
+ libutf8proc.$(MAJOR).dylib: utf8proc.o
+       $(cc) -dynamiclib -o $@ $^ -install_name $(libdir)/$@ 
-Wl,-compatibility_version -Wl,$(MAJOR) -Wl,-current_version 
-Wl,$(MAJOR).$(MINOR).$(PATCH)

diff --git a/dev-libs/utf8proc/metadata.xml b/dev-libs/utf8proc/metadata.xml
index f8fff5b..740304b 100644
--- a/dev-libs/utf8proc/metadata.xml
+++ b/dev-libs/utf8proc/metadata.xml
@@ -1,8 +1,8 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd";>
 <pkgmetadata>
-<herd>sci</herd>
-<longdescription>
+  <herd>sci</herd>
+  <longdescription>
   utf8proc is a library for processing UTF-8 encoded Unicode
   strings. Some features are Unicode normalization, stripping of
   default ignorable characters, case folding and detection of grapheme

diff --git a/dev-libs/utf8proc/utf8proc-1.2.ebuild 
b/dev-libs/utf8proc/utf8proc-1.2-r1.ebuild
similarity index 71%
rename from dev-libs/utf8proc/utf8proc-1.2.ebuild
rename to dev-libs/utf8proc/utf8proc-1.2-r1.ebuild
index 349806f..e00835d 100644
--- a/dev-libs/utf8proc/utf8proc-1.2.ebuild
+++ b/dev-libs/utf8proc/utf8proc-1.2-r1.ebuild
@@ -4,7 +4,7 @@
 
 EAPI=5
 
-inherit eutils
+inherit eutils toolchain-funcs
 
 DESCRIPTION="library for processing UTF-8 encoded Unicode strings"
 HOMEPAGE="http://www.public-software-group.org/utf8proc";
@@ -20,12 +20,17 @@ src_prepare() {
 }
 
 src_compile() {
-       emake libutf8proc.so
-       use static-libs & emake libutf8proc.a
+       emake \
+               libutf8proc.so \
+               $(usex static-libs libutf8proc.a "") \
+               CC=$(tc-getCC) \
+               AR=$(tc-getAR)
+#              CFLAGS="${CFLAGS}"
+#              LDFLAGS="${LDFLAGS} -Wl,--soname,lib${PN}.${PV}"
 }
 
 src_install() {
        doheader utf8proc.h
-       dolib.so libutf8proc.so
+       dolib.so libutf8proc.so*
        use static-libs && dolib.a libutf8proc.a
 }

Reply via email to