- Integrate the digest/*, racc/cparse, iconv, shim16_18 modules into

lang/ruby_static.

- Integrate the iconv module into lang/ruby_static-devel.
This commit is contained in:
Akinori MUSHA 2002-09-11 18:22:01 +00:00
parent c1c2cadd4a
commit 6288beb462
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=66162
4 changed files with 80 additions and 22 deletions

View file

@ -7,7 +7,7 @@
PORTNAME= ruby_static
PORTVERSION= ${RUBY_PORTVERSION}
PORTREVISION?= 0
PORTREVISION?= 1
CATEGORIES= lang ruby ipv6
MASTER_SITES= # none
DISTFILES= # none
@ -18,6 +18,8 @@ BUILD_DEPENDS= ${NONEXISTENT}:${.CURDIR}/../../${RUBY_PORT}:patch
USE_RUBY= yes
.include <bsd.port.pre.mk>
# Beware, because gdbm is under GPL, you must treat the whole binary
# as GPL says if you include gdbm in it.
EXT_PORTS= archivers/ruby-zlib \
@ -25,6 +27,14 @@ EXT_PORTS= archivers/ruby-zlib \
_PORTSDIR= ${.CURDIR}/../..
_RUBY_PORTDIR= ${_PORTSDIR}/${RUBY_PORT}
LIB_DEPENDS+= iconv.3:${PORTSDIR}/converters/libiconv
.if ${RUBY_VER} < 1.7
EXT_PORTS+= lang/ruby16-shim-ruby18
.else
EXT_PORTS+= converters/ruby-iconv
.endif
.for p in ${EXT_PORTS}
BUILD_DEPENDS+= ${NONEXISTENT}:${_PORTSDIR}/${p}:patch
.endfor
@ -46,8 +56,6 @@ WRKSRC= ${RUBY_WRKSRC}
DESCR= ${_RUBY_PORTDIR}/pkg-descr
.include <bsd.port.pre.mk>
# You can build a totally statically linked binary by defining STATIC,
# although it is not capable of loading dynamic modules.
@ -85,21 +93,40 @@ do-extract:
${MKDIR} ${WRKDIR}
${LN} -sf `cd ${_RUBY_PORTDIR} && ${MAKE} -V WRKSRC` ${WRKSRC}
.for p in ${EXT_PORTS}
m="${p:T:S,^ruby-,,}"; \
wrksrc=$$(cd ${_PORTSDIR}/${p} && ${MAKE} -V WRKSRC) ; \
extdir=$$(${FIND} -L $$wrksrc -name extconf.rb | \
${XARGS} ${GREP} -l create_makefile | ${HEAD} -1 ); \
extdir=$${extdir%/extconf.rb}; \
${CP} -RPp $$extdir ${WRKSRC}/ext/$$m; \
${TOUCH} ${WRKSRC}/ext/$$m/MANIFEST
${FIND} -L $$wrksrc -name extconf.rb | \
${XARGS} ${GREP} -l create_makefile | \
while read extdir; do \
extdir=$${extdir%/extconf.rb}; \
case "$p" in \
lang/ruby16-shim-ruby18) \
m=$$(basename $$extdir); \
case $$extdir in \
*/racc/*) \
${MKDIR} ${WRKSRC}/ext/racc; \
m=racc/$${m} ;; \
*/ext/features/ruby18/*) \
${MKDIR} ${WRKSRC}/ext/features/ruby18; \
m=features/ruby18/$${m}_ruby18 ;; \
esac ;; \
*) \
m="${p:T:S,^ruby-,,}" ;; \
esac; \
${CP} -RPp $$extdir ${WRKSRC}/ext/$$m; \
${TOUCH} ${WRKSRC}/ext/$$m/MANIFEST; \
done
.endfor
.if defined(STATIC)
${ECHO_CMD} "option nodynamic" > ${WRKSRC}/ext/Setup
.else
${ECHO_CMD} "#option nodynamic" > ${WRKSRC}/ext/Setup
.endif
(cd ${WRKSRC}/ext && \
for x in *; do [ -d $$x ] && echo $$x >> Setup; done)
cd ${WRKSRC}/ext; ${FIND} * -name extconf.rb | \
${XARGS} ${GREP} -l create_makefile | \
while read extdir; do \
extdir=$${extdir%/extconf.rb}; \
echo $$extdir; \
done >> Setup
.if defined(NEWAUTOCONF)
pre-configure:

View file

@ -7,6 +7,8 @@
MASTERDIR= ${.CURDIR}/../ruby_static
PORTREVISION= 1
RUBY_VER= 1.7
LATEST_LINK= ruby_static-devel

View file

@ -7,6 +7,8 @@
MASTERDIR= ${.CURDIR}/../ruby_static
PORTREVISION= 1
RUBY_VER= 1.7
LATEST_LINK= ruby_static-devel

View file

@ -7,7 +7,7 @@
PORTNAME= ruby_static
PORTVERSION= ${RUBY_PORTVERSION}
PORTREVISION?= 0
PORTREVISION?= 1
CATEGORIES= lang ruby ipv6
MASTER_SITES= # none
DISTFILES= # none
@ -18,6 +18,8 @@ BUILD_DEPENDS= ${NONEXISTENT}:${.CURDIR}/../../${RUBY_PORT}:patch
USE_RUBY= yes
.include <bsd.port.pre.mk>
# Beware, because gdbm is under GPL, you must treat the whole binary
# as GPL says if you include gdbm in it.
EXT_PORTS= archivers/ruby-zlib \
@ -25,6 +27,14 @@ EXT_PORTS= archivers/ruby-zlib \
_PORTSDIR= ${.CURDIR}/../..
_RUBY_PORTDIR= ${_PORTSDIR}/${RUBY_PORT}
LIB_DEPENDS+= iconv.3:${PORTSDIR}/converters/libiconv
.if ${RUBY_VER} < 1.7
EXT_PORTS+= lang/ruby16-shim-ruby18
.else
EXT_PORTS+= converters/ruby-iconv
.endif
.for p in ${EXT_PORTS}
BUILD_DEPENDS+= ${NONEXISTENT}:${_PORTSDIR}/${p}:patch
.endfor
@ -46,8 +56,6 @@ WRKSRC= ${RUBY_WRKSRC}
DESCR= ${_RUBY_PORTDIR}/pkg-descr
.include <bsd.port.pre.mk>
# You can build a totally statically linked binary by defining STATIC,
# although it is not capable of loading dynamic modules.
@ -85,21 +93,40 @@ do-extract:
${MKDIR} ${WRKDIR}
${LN} -sf `cd ${_RUBY_PORTDIR} && ${MAKE} -V WRKSRC` ${WRKSRC}
.for p in ${EXT_PORTS}
m="${p:T:S,^ruby-,,}"; \
wrksrc=$$(cd ${_PORTSDIR}/${p} && ${MAKE} -V WRKSRC) ; \
extdir=$$(${FIND} -L $$wrksrc -name extconf.rb | \
${XARGS} ${GREP} -l create_makefile | ${HEAD} -1 ); \
extdir=$${extdir%/extconf.rb}; \
${CP} -RPp $$extdir ${WRKSRC}/ext/$$m; \
${TOUCH} ${WRKSRC}/ext/$$m/MANIFEST
${FIND} -L $$wrksrc -name extconf.rb | \
${XARGS} ${GREP} -l create_makefile | \
while read extdir; do \
extdir=$${extdir%/extconf.rb}; \
case "$p" in \
lang/ruby16-shim-ruby18) \
m=$$(basename $$extdir); \
case $$extdir in \
*/racc/*) \
${MKDIR} ${WRKSRC}/ext/racc; \
m=racc/$${m} ;; \
*/ext/features/ruby18/*) \
${MKDIR} ${WRKSRC}/ext/features/ruby18; \
m=features/ruby18/$${m}_ruby18 ;; \
esac ;; \
*) \
m="${p:T:S,^ruby-,,}" ;; \
esac; \
${CP} -RPp $$extdir ${WRKSRC}/ext/$$m; \
${TOUCH} ${WRKSRC}/ext/$$m/MANIFEST; \
done
.endfor
.if defined(STATIC)
${ECHO_CMD} "option nodynamic" > ${WRKSRC}/ext/Setup
.else
${ECHO_CMD} "#option nodynamic" > ${WRKSRC}/ext/Setup
.endif
(cd ${WRKSRC}/ext && \
for x in *; do [ -d $$x ] && echo $$x >> Setup; done)
cd ${WRKSRC}/ext; ${FIND} * -name extconf.rb | \
${XARGS} ${GREP} -l create_makefile | \
while read extdir; do \
extdir=$${extdir%/extconf.rb}; \
echo $$extdir; \
done >> Setup
.if defined(NEWAUTOCONF)
pre-configure: