Date: Wed, 30 Jul 2014 19:42:51 +0000 (UTC) From: Kurt Jaeger <pi@FreeBSD.org> To: ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org Subject: svn commit: r363509 - in head: . lang lang/sml-nj lang/sml-nj-devel lang/smlnj lang/smlnj/files Message-ID: <201407301942.s6UJgpx1000840@svn.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: pi Date: Wed Jul 30 19:42:50 2014 New Revision: 363509 URL: http://svnweb.freebsd.org/changeset/ports/363509 QAT: https://qat.redports.org/buildarchive/r363509/ Log: lang/smlnj: 110.71 -> 110.76 - unbreak and support staging - support amd64 - no longer depends on gmake - moves lang/sml-nj-devel to lang/smlnj - supersedes lang/sml-nj PR: 191899 Reviewed by: Robert Cina <transitive@gmail.com>, Timothy Beyer <beyert@cs.ucr.edu> Approved by: Johannes <joemann@beefree.free.de> (maintainer) Added: head/lang/smlnj/ - copied from r363497, head/lang/sml-nj-devel/ head/lang/smlnj/files/do-patch-base_runtime_objs_makefile (contents, props changed) head/lang/smlnj/files/do-patch-base_runtime_objs_mk.x86-freebsd (contents, props changed) head/lang/smlnj/files/extra-patch-base_runtime_c-libs_smlnj-math_ctlrndmode.c (contents, props changed) head/lang/smlnj/files/extra-patch-base_runtime_include_freebsd-8-i386-__types.h (contents, props changed) head/lang/smlnj/files/extra-patch-base_runtime_include_freebsd-8-i386-endian.h (contents, props changed) head/lang/smlnj/files/extra-patch-base_runtime_include_freebsd-8-i386-ieeefp.h (contents, props changed) head/lang/smlnj/files/extra-patch-base_runtime_include_freebsd-8-i386-signal.h (contents, props changed) head/lang/smlnj/files/extra-patch-base_runtime_include_freebsd-9-i386-__types.h (contents, props changed) head/lang/smlnj/files/extra-patch-base_runtime_include_freebsd-9-i386-endian.h (contents, props changed) head/lang/smlnj/files/extra-patch-base_runtime_include_ml-unixdep.h (contents, props changed) head/lang/smlnj/files/patch-config___arch-n-opsys (contents, props changed) head/lang/smlnj/files/patch-config___heap2exec (contents, props changed) Deleted: head/lang/sml-nj/ head/lang/sml-nj-devel/ head/lang/smlnj/files/plist-everything Modified: head/MOVED head/lang/Makefile head/lang/smlnj/Makefile head/lang/smlnj/distinfo head/lang/smlnj/files/patch-config_install.sh head/lang/smlnj/files/pkg-install.in head/lang/smlnj/pkg-descr head/lang/smlnj/pkg-plist Modified: head/MOVED ============================================================================== --- head/MOVED Wed Jul 30 19:35:36 2014 (r363508) +++ head/MOVED Wed Jul 30 19:42:50 2014 (r363509) @@ -6353,3 +6353,5 @@ devel/cl-trivial-gray-streams-clisp||201 lang/clisp||2014-07-28|Has expired: development has ceased, not staged print/texpower|print/texlive-texmf|2014-07-28|Has been incorporated in TeXLive print/tex-mfpic|print/texlive-texmf|2014-07-28|Has been incorporated in TeXLive +lang/sml-nj-devel|lang/smlnj|2014-07-30|The -devel was updated and is now production-ready +lang/sml-nj|lang/smlnj|2014-07-30|Use lang/smlnj as newer version Modified: head/lang/Makefile ============================================================================== --- head/lang/Makefile Wed Jul 30 19:35:36 2014 (r363508) +++ head/lang/Makefile Wed Jul 30 19:42:50 2014 (r363509) @@ -305,8 +305,7 @@ SUBDIR += slisp SUBDIR += smalltalk SUBDIR += sml-mode.el - SUBDIR += sml-nj - SUBDIR += sml-nj-devel + SUBDIR += smlnj SUBDIR += snobol4 SUBDIR += spidermonkey17 SUBDIR += spidermonkey170 Modified: head/lang/smlnj/Makefile ============================================================================== --- head/lang/sml-nj-devel/Makefile Wed Jul 30 17:24:07 2014 (r363497) +++ head/lang/smlnj/Makefile Wed Jul 30 19:42:50 2014 (r363509) @@ -1,61 +1,96 @@ -# Created by: Joseph Koshy <jkoshy@FreeBSD.org> # $FreeBSD$ PORTNAME= smlnj -PORTVERSION= 110.71 +PORTVERSION= 110.76 CATEGORIES= lang MASTER_SITES= http://smlnj.cs.uchicago.edu/dist/working/${PORTVERSION}/ \ ftp://mirror.free.de/http/smlnj.cs.uchicago.edu/dist/working/${PORTVERSION}/ -PKGNAMESUFFIX= -devel DISTFILES= config.tgz runtime.tgz -DIST_SUBDIR= sml-nj/${PORTVERSION} +DIST_SUBDIR= smlnj/${PORTVERSION} EXTRACT_ONLY= config.tgz MAINTAINER= joemann@beefree.free.de -COMMENT= Popular functional language from Bell Labs - -BROKEN= Dysfunctional +COMMENT= Compiler and tools for Standard ML (SML '97) NO_WRKSUBDIR= yes -USES= gmake - -ONLY_FOR_ARCHS= i386 - -OPTIONS_DEFINE= EVERYTHING RECOMPILE POSITION64 -EVERYTHING_DESC= install everything from the SML/NJ distribution -RECOMPILE_DESC= recompile the SML compiler - implies EVERYTHING -POSITION64_DESC= use 64bit fi""le positions - implies RECOMPILE SUB_FILES= pkg-install SUB_LIST= EXEBINDIR=${MLBINRELATIVE} EXENAMES="${MLEXE}" PKGDEINSTALL= ${PKGINSTALL} -NO_STAGE= yes +# Calm portlint +CALM= + +OPTIONS_RADIO= RG1 +OPTIONS_RADIO_RG1= EVERYTHING RECOMPILE POSITION64 +OPTIONS_EXCLUDE_amd64= RECOMPILE POSITION64 +EVERYTHING_DESC= install${CALM} everything from the SML/NJ distribution +RECOMPILE_DESC= recompile the SML compiler - implies EVERYTHING +POSITION64_DESC= use 64bit file${CALM} positions - implies RECOMPILE + .include <bsd.port.pre.mk> -.if (${ARCH} == "i386") +# Recompiling the compiler currently fails on amd64 +.if ${ARCH} == "i386" +ML_RECOMPILE_OPTIONS= RECOMPILE POSITION64 +.endif + +.if (${ARCH} == "amd64") && (${OSVERSION} >= 1000029) +ONLY_FOR_ARCHS= i386 amd64 +.elif (${ARCH} == "amd64") && (${OSVERSION} >= 800000) +ONLY_FOR_ARCHS= i386 amd64 +# Compilation of the i386 runtime source on older amd64 systems requires +# i386 system headers from the respective FreeBSD Version, taken from +# stable/N/sys/i386/include, r196045 (N=8) and r225736 (N=9). +EXTRA_DEFS+= -DINCLUDE_FREEBSD_I386_SIGNAL=\\\"freebsd-8-i386-signal.h\\\" +EXTRA_DEFS+= -DINCLUDE_FREEBSD_I386_IEEEFP=\\\"freebsd-8-i386-ieeefp.h\\\" +.if (${OSVERSION} < 900000) +EXTRA_DEFS+= -DINCLUDE_FREEBSD_I386__TYPES=\\\"freebsd-8-i386-_types.h\\\" +EXTRA_DEFS+= -DINCLUDE_FREEBSD_I386_ENDIAN=\\\"freebsd-8-i386-endian.h\\\" +.else +EXTRA_DEFS+= -DINCLUDE_FREEBSD_I386__TYPES=\\\"freebsd-9-i386-_types.h\\\" +EXTRA_DEFS+= -DINCLUDE_FREEBSD_I386_ENDIAN=\\\"freebsd-9-i386-endian.h\\\" +.endif +.else +ONLY_FOR_ARCHS= i386 +.endif + +.if (${ARCH} == "amd64") +CFLAGS+= -m32 +AS?= as +AS+= --32 +.endif +.if (${ARCH} == "i386" || ${ARCH} == "amd64") MLARCH= x86 DISTFILES+= boot.x86-unix.tgz .endif -DISTFILES+= MLRISC.tgz ckit.tgz cml.tgz heap2asm.tgz ml-lpt.tgz \ - ml-lex.tgz ml-yacc.tgz smlnj-lib.tgz trace-debug-profile.tgz +DISTFILES+= MLRISC.tgz ckit.tgz cml.tgz heap2asm.tgz ml-burg.tgz \ + ml-lpt.tgz ml-lex.tgz ml-yacc.tgz nlffi.tgz \ + smlnj-lib.tgz trace-debug-profile.tgz PLIST_SUB= MLARCH=${MLARCH} -.if ${PORT_OPTIONS:MPOSITION64} -WITH_RECOMPILE?= ${WITH_POSITION64} +.if ${PORT_OPTIONS:MPOSITION64} || defined(ML_POSITION64) +ML_POSITION64?= ${PORT_OPTIONS:MPOSITION64} +ML_RECOMPILE?= ${ML_POSITION64} +ML_EVERYTHING?= ${ML_POSITION64} CMB_COMMAND= '(\#set o CMB.symval) "USE_64_BIT_POSITIONS" (SOME 1);' .else CMB_COMMAND= .endif -.if ${PORT_OPTIONS:MRECOMPILE} -WITH_EVERYTHING?= ${WITH_RECOMPILE} +.if ${PORT_OPTIONS:MRECOMPILE} || defined(ML_RECOMPILE) +ML_RECOMPILE?= ${PORT_OPTIONS:MRECOMPILE} +ML_EVERYTHING?= ${ML_RECOMPILE} .endif -.if ${PORT_OPTIONS:MEVERYTHING} -DISTFILES+= cm.tgz compiler.tgz eXene.tgz ml-burg.tgz \ - nlffi.tgz pgraph.tgz smlnj-c.tgz system.tgz +.if ${PORT_OPTIONS:MEVERYTHING} || defined(ML_EVERYTHING) +ML_EVERYTHING?= ${PORT_OPTIONS:MEVERYTHING} +DISTFILES+= cm.tgz compiler.tgz eXene.tgz \ + pgraph.tgz smlnj-c.tgz system.tgz +PLIST_SUB+= EVERYTHING="" +.else +PLIST_SUB+= EVERYTHING="@comment " .endif MLROOTRELATIVE= smlnj @@ -63,44 +98,40 @@ MLROOT= ${PREFIX}/${MLROOTRELATIVE} MLBINRELATIVE= ${MLROOTRELATIVE}/bin MLBIN= ${MLROOT}/bin MLLIB= ${MLROOT}/lib -MLSTDSRCDIRS= cml heap2asm ml-lex ml-lpt ml-yacc smlnj-lib +MLSTDSRCDIRS= cml heap2asm ml-burg ml-lex ml-lpt ml-yacc nlffi smlnj-lib MLSRCDIRS= base ${MLSTDSRCDIRS} \ - ckit eXene ml-burg nlffi pgraph smlnj-c + ckit eXene pgraph smlnj-c MLSRCS= .for srcdir in ${MLSRCDIRS} MLSRCS+= ${MLROOT}/${srcdir} .endfor MLTARGETS= heap2asm -MLEXE= heap2exec ml-antlr ml-build ml-lex ml-makedepend \ - ml-ulex ml-yacc sml -.if ${PORT_OPTIONS:MEVERYTHING} -MLTARGETS+= eXene ml-burg ml-nlffi-lib ml-nlffigen \ - mlrisc-tools nowhere pgraph-util src-smlnj -MLEXE+= ml-burg ml-nlffigen nowhere +MLEXE= heap2exec ml-antlr ml-build ml-burg ml-lex ml-makedepend \ + ml-nlffigen ml-ulex ml-yacc sml +.if defined(ML_EVERYTHING) +MLTARGETS+= eXene mlrisc-tools nowhere pgraph-util src-smlnj +MLEXE+= nowhere PLIST= ${WRKDIR}/.PLIST MLRUNTIMEPLIST= ${WRKDIR}/.PLIST-runtime MLSRCPLIST= ${WRKDIR}/.PLIST-src -MLPLISTFILES= ${.CURDIR}/pkg-plist ${FILESDIR}/plist-everything \ - ${MLRUNTIMEPLIST} ${MLSRCPLIST} +MLPLISTFILES= ${.CURDIR}/pkg-plist ${MLRUNTIMEPLIST} ${MLSRCPLIST} .endif pre-fetch: @${ECHO} -.if ! ${PORT_OPTIONS:MEVERYTHING} - @${ECHO} 'Use make WITH_EVERYTHING=yes to also build/install' +.if ! defined(ML_EVERYTHING) + @${ECHO} 'Use make ML_EVERYTHING=yes to also build/install' @${ECHO} ' eXene (X Windows toolkit),' - @${ECHO} ' ml-burg (tree transformer),' - @${ECHO} ' ml-nlffi (foreign function interface to C code),' @${ECHO} ' nowhere (preprocessor for conditional patterns),' @${ECHO} ' various libraries, and all the sources.' .endif -.if ! ${PORT_OPTIONS:MRECOMPILE} - @${ECHO} 'Use make WITH_RECOMPILE=yes to recompile the compiler.' - @${ECHO} ' This implies WITH_EVERYTHING.' -.endif -.if ! ${PORT_OPTIONS:MPOSITION64} - @${ECHO} 'Use make WITH_POSITION64=yes to use 64bit file positions.' - @${ECHO} ' This implies WITH_RECOMPILE.' +.if !empty(ML_RECOMPILE_OPTIONS:MRECOMPILE) && !defined(ML_RECOMPILE) + @${ECHO} 'Use make ML_RECOMPILE=yes to recompile the compiler.' + @${ECHO} ' This implies ML_EVERYTHING.' +.endif +.if !empty(ML_RECOMPILE_OPTIONS:MPOSITION64) && !defined(ML_POSITION64) + @${ECHO} 'Use make ML_POSITION64=yes to use 64bit file positions.' + @${ECHO} ' This implies ML_RECOMPILE.' .endif @${ECHO} @@ -109,7 +140,7 @@ pre-fetch: post-extract: cd ${WRKDIR} && ${LN} -sf ${_DISTDIR}/* . -# Configuring is done by uncommenting the appropriate #request xxx +# Configuring is done by uncommenting the appropriate #request # lines of config/targets. Dependency details are handled by # base/system/smlnj/installer using config/dependencies and # config/actions. @@ -125,7 +156,7 @@ do-configure: # Recompilation requires ml-lex and ml-yacc. All requested targets # will be built later using the recompiled core system after # removing targets.customized. See "do-build" below. -.if ${PORT_OPTIONS:MRECOMPILE} +.if defined(ML_RECOMPILE) ( ${ECHO_CMD} "request ml-yacc" && \ ${ECHO_CMD} "request ml-lex" && \ ${ECHO_CMD} "request ml-lex-mllex-tool" && \ @@ -138,15 +169,21 @@ do-configure: # a subsequent make install. # See base/system/README for information on recompiling the compiler. -.if ${PORT_OPTIONS:MRECOMPILE} +.if defined(ML_RECOMPILE) RECOMPILEDIR= base/system .else RECOMPILEDIR= .endif +.if (${ARCH} == "amd64") && (${OSVERSION} >= 800000) && (${OSVERSION} < 1000029) +MLRUNTIMEPATCHES_CMD= cd ${FILESDIR} && \ + ( ${LS} do-patch-base_runtime_* extra-patch-base_runtime_* 2>&- || \ + ${TRUE} ) +.else MLRUNTIMEPATCHES_CMD= cd ${FILESDIR} && \ ( ${LS} do-patch-base_runtime_* 2>&- || \ ${TRUE} ) +.endif MLSTANDARDPATCHES_CMD= cd ${FILESDIR} && \ ( for srcdir in ${MLSTDSRCDIRS} ; \ do ${LS} do-patch-$${srcdir}_* 2>&- ; \ @@ -156,7 +193,7 @@ MLSTANDARDPATCHDIRS_CMD= cd ${FILESDIR} do if ${LS} do-patch-$${srcdir}_* 1>&- 2>&- ; \ then ${ECHO_CMD} -n $${srcdir} " " ; break ; fi ; \ done ) || ${TRUE} -.if ${PORT_OPTIONS:MEVERYTHING} +.if defined(ML_EVERYTHING) MLSOURCEPATCHES_CMD= cd ${FILESDIR} && \ ( ${LS} do-patch-* 2>&- || \ ${TRUE} ) @@ -172,8 +209,9 @@ do-build: MLSTANDARDPATCHES=`${MLSTANDARDPATCHES_CMD}` \ MLSTANDARDPATCHDIRS=`${MLSTANDARDPATCHDIRS_CMD}` \ MLSOURCEPATCHES=`${MLSOURCEPATCHES_CMD}` \ + CFLAGS='${CFLAGS}' AS='${AS}' EXTRA_DEFS='${EXTRA_DEFS}' \ ./config/install.sh -.if ${PORT_OPTIONS:MRECOMPILE} +.if defined(ML_RECOMPILE) -${RM} ${WRKDIR}/config/targets.customized @${ECHO} '(* Recompiling the core system: *)' cd ${WRKDIR}/${RECOMPILEDIR} && ( \ @@ -196,15 +234,16 @@ do-build: cd ${WRKDIR} && unset PWD && \ FILESDIR="${FILESDIR}" PATCH="${PATCH}" PATCH_ARGS="${PATCH_ARGS}" \ MLNORUNTIMECLEAN=yes RECOMPILEDIR="${RECOMPILEDIR}" \ + CFLAGS='${CFLAGS}' AS='${AS}' EXTRA_DEFS='${EXTRA_DEFS}' \ ./config/install.sh .endif # Nowadays PLIST has to be computed before installation. We do it in # "pre-install" because source extraction happens during "build". -.if ${PORT_OPTIONS:MEVERYTHING} +.if defined(ML_EVERYTHING) MLNOINSTALL= .cm -.if ${PORT_OPTIONS:MRECOMPILE} +.if defined(ML_RECOMPILE) MLNOINSTALL+= sml.bin.${MLARCH}-unix sml.boot.${MLARCH}-unix \ sml.lib sml.${MLARCH}-bsd .endif @@ -215,37 +254,65 @@ MLSRCEXCLUDEREGEX+= -e '/${excl}$$' -e ' MLPATCHPATHREGEX= -E -e 's%(^|[^_])_([^_]|$$)%\1/\2%g' \ -e 's%(^|[^_])__([^_]|$$)%\1_\2%g' \ -e 's%(^|[^_])___([^_]|$$)%\1/_\2%g' +.endif pre-install: +.if defined(ML_EVERYTHING) @${ECHO} -n '(* Computing package list ...' @${TAR} -tzf ${WRKDIR}/runtime.tgz | \ ${SED} -E -e 's%^(.*[^/])$$%${MLROOTRELATIVE}/base/\1%' \ -e 's%^(.*)/$$%@dirrm\ ${MLROOTRELATIVE}/base/\1%' \ > ${MLRUNTIMEPLIST} - `${MLRUNTIMEPATCHES_CMD}` | \ + @${MLRUNTIMEPATCHES_CMD} | \ + ${SED} ${MLPATCHPATHREGEX} | \ + ${SED} -E -e 's%^(do|extra)-patch-(base/.*)%${MLROOTRELATIVE}/\2%' \ + > ${MLRUNTIMEPLIST}.patched + -@${GREP} -F -v -f ${MLRUNTIMEPLIST} ${MLRUNTIMEPLIST}.patched \ + > ${MLRUNTIMEPLIST}.patchednew + @${CAT} ${MLRUNTIMEPLIST}.patchednew >> ${MLRUNTIMEPLIST} + @${MLRUNTIMEPATCHES_CMD} | \ ${SED} ${MLPATCHPATHREGEX} | \ - ${SED} -E -e 's%^do-patch-(base/.*)%${MLROOTRELATIVE}/\1.orig%' \ + ${SED} -E -e 's%^(do|extra)-patch-(base/.*)%${MLROOTRELATIVE}/\2.orig%' \ >> ${MLRUNTIMEPLIST} @cd "${WRKDIR}" && ( \ ( ${FIND} -s -d ${MLSRCDIRS} \! -type d | \ ${AWK} '{ print "${MLROOTRELATIVE}/" $$0 }' ) ; \ ( ${FIND} -s -d ${MLSRCDIRS} -type d -empty | \ - ${AWK} '{ print "@exec mk""dir -p %D/${MLROOTRELATIVE}/" $$0 }' ) ; \ + ${AWK} '{ print "@exec mkdir${CALM} -p %D/${MLROOTRELATIVE}/" $$0 }' ) ; \ ( ${FIND} -s -d ${MLSRCDIRS} -type d | \ ${AWK} '{ print "@dirrm ${MLROOTRELATIVE}/" $$0 }' ) ) | \ ${EGREP} -v ${MLSRCEXCLUDEREGEX} > ${MLSRCPLIST} - @${GREP} -h "^[^@]" ${MLPLISTFILES} | ${SORT} -u > ${PLIST} - @${GREP} -h "^@exec mk""dir" ${MLPLISTFILES} | ${SORT} -u >> ${PLIST} - @${GREP} -h "^@dirrm" ${MLPLISTFILES} | ${SORT} -r -u >> ${PLIST} + @${SED} -e 's/^%%EVERYTHING%%//' ${MLPLISTFILES} | \ + ${GREP} -h -v "^@dirrm" | ${SORT} -u > ${PLIST} + @${GREP} -h "^@exec mkdir${CALM}" ${MLPLISTFILES} | ${SORT} -u >> ${PLIST} + @${SED} -e 's/^%%EVERYTHING%%//' ${MLPLISTFILES} | \ + ${GREP} -h "^@dirrm" | ${SORT} -r -u >> ${PLIST} @${ECHO} ' done. *)' .endif +# ${PKGINSTALL} contains multiexec-wrapper, which is used to select +# between executables of the same name that have been installed by +# different packages (like smlnj and smlnj-devel). The source of +# multiexec-wrapper is extracted from ${PKGINSTALL}, and inserted +# into ${PKGINSTALL} in compressed and encoded form. So it is still +# available when being installed from a binary package, even if +# ${PKGINSTALL} is no file at that time (but only input to a shell). + @${SED} -e '/^#%%PKG-INSTALL-START%%$$/,/^#%%PKG-INSTALL-END%%$$/d' \ + ${PKGINSTALL} > ${PKGINSTALL}.script + @${GZIP_CMD} ${PKGINSTALL}.script + @b64encode ${PKGINSTALL}.script.gz script.gz > ${PKGINSTALL}.script.gz.b64 + @${SED} -n -e '1,/~EOF~.$$/p' ${PKGINSTALL} > ${PKGINSTALL}.pre + @${SED} -n -e '/^~EOF~$$/,$$p' ${PKGINSTALL} > ${PKGINSTALL}.post + @${CAT} ${PKGINSTALL}.pre ${PKGINSTALL}.script.gz.b64 ${PKGINSTALL}.post > ${PKGINSTALL}.full + @${DIFF} -q ${PKGINSTALL} ${PKGINSTALL}.full >/dev/null || ${CP} ${PKGINSTALL}.full ${PKGINSTALL} # The install target installs the heaps and libraries to their final # location in ${MLBIN} and ${MLLIB}. # In case of recompilation, installml installs the sml heap and the # libraries built during compiler bootstrap to ${MLBIN} and ${MLLIB}. +# When staging CM_PATHCONFIG has to point to the final +# ${MLLIB}/pathconfig (in ${PREFIX}) while building the compiler. -.if ${PORT_OPTIONS:MEVERYTHING} +.if defined(ML_EVERYTHING) MLSRCEXCLUDES= .for excl in ${MLNOINSTALL} MLSRCEXCLUDES+= --exclude "${excl}" @@ -253,11 +320,14 @@ MLSRCEXCLUDES+= --exclude "${excl}" .endif do-install: - ${MKDIR} "${MLROOT}" -.if ! ${PORT_OPTIONS:MRECOMPILE} + ${MKDIR} "${STAGEDIR}${MLROOT}" +.if ! defined(ML_RECOMPILE) cd ${WRKDIR} && unset PWD && \ FILESDIR="${FILESDIR}" PATCH="${PATCH}" PATCH_ARGS="${PATCH_ARGS}" \ - INSTALLDIR="${MLROOT}" ./config/install.sh + STAGEDIR="${STAGEDIR}" MLLIB="${MLLIB}" \ + INSTALLDIR="${STAGEDIR}${MLROOT}" \ + CFLAGS='${CFLAGS}' AS='${AS}' EXTRA_DEFS='${EXTRA_DEFS}' \ + ./config/install.sh .else @${ECHO} '(* Rebuilding the recompiled libs: *)' cd ${WRKDIR}/${RECOMPILEDIR} && ( \ @@ -271,26 +341,33 @@ do-install: @${ECHO} '(* Installing into ${MLROOT}: *)' cd ${WRKDIR} && unset PWD && \ FILESDIR="${FILESDIR}" PATCH="${PATCH}" PATCH_ARGS="${PATCH_ARGS}" \ - INSTALLDIR="${MLROOT}" RECOMPILEDIR="${RECOMPILEDIR}" \ + STAGEDIR="${STAGEDIR}" MLLIB="${MLLIB}" \ + INSTALLDIR="${STAGEDIR}${MLROOT}" RECOMPILEDIR="${RECOMPILEDIR}" \ + CFLAGS='${CFLAGS}' AS='${AS}' EXTRA_DEFS='${EXTRA_DEFS}' \ ./config/install.sh .endif - MLARCHOPSYS=`${MLBIN}/.arch-n-opsys` && \ + MLARCHOPSYS=`${STAGEDIR}${MLBIN}/.arch-n-opsys` && \ ( eval $${MLARCHOPSYS} ; \ - ${STRIP_CMD} "${MLBIN}/.run/run.$${ARCH}-$${OPSYS}" ) - @${CHOWN} -R ${BINOWN}:${BINGRP} "${MLBIN}" "${MLLIB}" -.if ${PORT_OPTIONS:MEVERYTHING} + ${STRIP_CMD} "${STAGEDIR}${MLBIN}/.run/run.$${ARCH}-$${OPSYS}" ) +.if defined(ML_EVERYTHING) @${ECHO} '(* Cleaning base/runtime: *)' cd ${WRKDIR}/base/runtime/objs && ${MAKE_CMD} clean - @${ECHO} -n '(* Installing sources into ${MLROOT} ...' + @${ECHO} -n '(* Installing sources into ${STAGEDIR}${MLROOT} ...' @cd ${WRKDIR} && ${TAR} -cf - ${MLSRCEXCLUDES} ${MLSRCDIRS} | \ - ${TAR} -xf - -C "${MLROOT}" - @${CHOWN} -R ${SHAREOWN}:${SHAREGRP} ${MLSRCS} + ${TAR} -xf - -C "${STAGEDIR}${MLROOT}" @${ECHO} ' done. *)' .endif post-install: +# Only execute ${PKGINSTALL} when installing to ${PREFIX}, +# but not when staging. +.ifmake install${CALM} PKG_PREFIX=${PREFIX} MULTIEXEC_WRAPPER_VERBOSE=yes \ ${SH} ${PKGINSTALL} ${PKGNAME} POST-INSTALL +.endif + +post-stage: + ${STRIP_CMD} ${STAGEDIR}${PREFIX}/smlnj/bin/.run/run.x86-freebsd.so .ifndef MULTIEXEC_WRAPPER_VERBOSE deinstall: @@ -298,14 +375,14 @@ deinstall: cd ${.CURDIR} && ${MAKE} ${.MAKEFLAGS} deinstall .endif -# This target may be used by dependent ports to set SMLNJ_DEVEL_VERSION -# either to the currently installed sml-nj-devel package's version -# or else to this port's version. SMLNJ_DEVEL_VERSION is an environment +# This target may be used by dependent ports to set SMLNJ_VERSION +# either to the currently installed smlnj package's version +# or else to this port's version. SMLNJ_VERSION is an environment # variable used by multiexec-wrapper to select the executable -# from that smlnj-devel-* package matching SMLNJ_DEVEL_VERSION. -smlnj-devel-version: - @${EXPR} `${PKG_INFO} -q -O lang/sml-nj-devel` : '.*-\(.*\)' \ - 2>/dev/null || \ +# from that smlnj-* package matching SMLNJ_VERSION. +smlnj-version: + @{ ${PKG_INFO} -e smlnj && \ + ${EXPR} `${PKG_INFO} -E smlnj` : '.*-\(.*\)' 2>/dev/null ; } || \ ${ECHO_CMD} ${PKGVERSION} .include <bsd.port.post.mk> Modified: head/lang/smlnj/distinfo ============================================================================== --- head/lang/sml-nj-devel/distinfo Wed Jul 30 17:24:07 2014 (r363497) +++ head/lang/smlnj/distinfo Wed Jul 30 19:42:50 2014 (r363509) @@ -1,40 +1,40 @@ -SHA256 (sml-nj/110.71/MLRISC.tgz) = fe86100738b12fb7edbbddf66626b96d4d13c149dd71e0cfb8132a92a7522ae1 -SIZE (sml-nj/110.71/MLRISC.tgz) = 1435231 -SHA256 (sml-nj/110.71/boot.x86-unix.tgz) = 2f1a41e6639963a5c09b453d941c4ac7c62d5043e2cc2b25d2a18feb7517bc04 -SIZE (sml-nj/110.71/boot.x86-unix.tgz) = 5849700 -SHA256 (sml-nj/110.71/ckit.tgz) = fc8320898b17106bf759bc813c69aecfe1732d0c13e9b54ed5522920bbd562a7 -SIZE (sml-nj/110.71/ckit.tgz) = 199404 -SHA256 (sml-nj/110.71/cm.tgz) = 40bb024769f28a70b45e4ad87bb781c1277c4fa0de7ae1b5109263ed073c0300 -SIZE (sml-nj/110.71/cm.tgz) = 202311 -SHA256 (sml-nj/110.71/cml.tgz) = 469f013db2e6abae40db34f4e78c0ce556a730c6b9a567eea35df7aa2f6b1f96 -SIZE (sml-nj/110.71/cml.tgz) = 104707 -SHA256 (sml-nj/110.71/compiler.tgz) = 3040cc3fed1f2b00f33d290bd52e999a8ea73d2ba847bbe5b16165276c07afaf -SIZE (sml-nj/110.71/compiler.tgz) = 825457 -SHA256 (sml-nj/110.71/config.tgz) = accafba082cb3b7e2bbfff3221bbe49dcfb8029a5d6f8002f98597890870a3be -SIZE (sml-nj/110.71/config.tgz) = 512911 -SHA256 (sml-nj/110.71/eXene.tgz) = 23b12302c8fdeb4c94918cf1c24739c72f01114597b3bfef817c58943ec2c467 -SIZE (sml-nj/110.71/eXene.tgz) = 714564 -SHA256 (sml-nj/110.71/heap2asm.tgz) = 01cae1f1d5217405e367d0efd1385161602d3f0828f54e794190baa13d733d0f -SIZE (sml-nj/110.71/heap2asm.tgz) = 1326 -SHA256 (sml-nj/110.71/ml-burg.tgz) = 429f2e974db4131c74eea141902491af9df1d55bc2c0767356434bab13b90dd5 -SIZE (sml-nj/110.71/ml-burg.tgz) = 36670 -SHA256 (sml-nj/110.71/ml-lex.tgz) = 0a951e91caa43e025eeaa03879764e93519e82ace817eaf86d5c0f469360322b -SIZE (sml-nj/110.71/ml-lex.tgz) = 33060 -SHA256 (sml-nj/110.71/ml-lpt.tgz) = e5c3489a9d60d4d45a266240e380a497b05f8f45ba44da83a704c4388cf664d1 -SIZE (sml-nj/110.71/ml-lpt.tgz) = 254684 -SHA256 (sml-nj/110.71/ml-yacc.tgz) = 3e5b9ec0af3704c7045a43d974902abddecefd8d25a41225b06b7390dcf29453 -SIZE (sml-nj/110.71/ml-yacc.tgz) = 102023 -SHA256 (sml-nj/110.71/nlffi.tgz) = dc23c4ea4101f918fe5f92622c9b34b88cb91c62c2c41911e7117a7aa389f44a -SIZE (sml-nj/110.71/nlffi.tgz) = 75182 -SHA256 (sml-nj/110.71/pgraph.tgz) = e9514a3c8c002627bf2297bca020028d6d27a6a3c31f940db1dcf2dc3941885b -SIZE (sml-nj/110.71/pgraph.tgz) = 5454 -SHA256 (sml-nj/110.71/runtime.tgz) = ec6d38c782876db979a7b03444ded0bfaa0154d8e88c0a7befa6836f9b235763 -SIZE (sml-nj/110.71/runtime.tgz) = 334109 -SHA256 (sml-nj/110.71/smlnj-c.tgz) = 1ae91e81e77b422367f34fa1bedced1235ba0da5363b075e62bc0d39a55e8fde -SIZE (sml-nj/110.71/smlnj-c.tgz) = 10625 -SHA256 (sml-nj/110.71/smlnj-lib.tgz) = 3dd4cbe21bd9d2917d22d8b793776e6c519f175ddb96f6339f890f69d54feda9 -SIZE (sml-nj/110.71/smlnj-lib.tgz) = 259309 -SHA256 (sml-nj/110.71/system.tgz) = 6279962f447ce17df64a3c52e8c10f98f0e09b41d5418077d5880a9445eb3ad3 -SIZE (sml-nj/110.71/system.tgz) = 239973 -SHA256 (sml-nj/110.71/trace-debug-profile.tgz) = 3b4db9f3546c02ce5c4510e070ee304b768914914e47acdbae3a82397df1ac28 -SIZE (sml-nj/110.71/trace-debug-profile.tgz) = 3935 +SIZE (smlnj/110.76/MLRISC.tgz) = 1434516 +SHA256 (smlnj/110.76/MLRISC.tgz) = 9d944dea4e80a8ef2cc01e7e16ae72cb280f2e4dc0d6648c9bc27156ccfcc102 +SIZE (smlnj/110.76/boot.x86-unix.tgz) = 5890950 +SHA256 (smlnj/110.76/boot.x86-unix.tgz) = dd16569fb6991d673e66dae57f5e9b372d5a4e305f92a9756002e4bb296c9b61 +SIZE (smlnj/110.76/ckit.tgz) = 194486 +SHA256 (smlnj/110.76/ckit.tgz) = c4534e6e7f910ebee3146cc8ed214a1d5a2ea90afbd79c2290cefdc784ee0dbb +SIZE (smlnj/110.76/cm.tgz) = 200425 +SHA256 (smlnj/110.76/cm.tgz) = 539e8199764a803f486dbf5c0ecb3fa3b2277a6b52ccbbf350bbdcc231bec193 +SIZE (smlnj/110.76/cml.tgz) = 106005 +SHA256 (smlnj/110.76/cml.tgz) = cbd357a3b3377d049911a247be880dcde7f52f705f7cdfe800b67631858681e1 +SHA256 (smlnj/110.76/compiler.tgz) = 322755b8a3f105eec4ce4a3197aaf83bcd542e4c2b2f43c724d0ae8f393bf681 +SIZE (smlnj/110.76/compiler.tgz) = 817182 +SHA256 (smlnj/110.76/config.tgz) = 41cec8bd28c43f49bea24cc7d80d091d8a0e0c7473ee67e4a0b06019567ca557 +SIZE (smlnj/110.76/config.tgz) = 511139 +SHA256 (smlnj/110.76/eXene.tgz) = 35befa7d37207c7fc2eab81e29e3a5afb4f2c5893f7336394906425d5f4ee607 +SIZE (smlnj/110.76/eXene.tgz) = 703059 +SIZE (smlnj/110.76/heap2asm.tgz) = 1314 +SHA256 (smlnj/110.76/heap2asm.tgz) = 8c1f52bc7459de1d0d8e07807abb8e8916fa5ef1cf08c0ceb3f06437f977215d +SIZE (smlnj/110.76/ml-burg.tgz) = 36341 +SHA256 (smlnj/110.76/ml-burg.tgz) = d59dad9188778c96b3e59f9d754a4fbdef4b67de2ded67deb0d26c40915a594e +SIZE (smlnj/110.76/ml-lex.tgz) = 33150 +SHA256 (smlnj/110.76/ml-lex.tgz) = 9d00143cff4e8cc87421270d34b29864c27d353d6b429cce3d3428f6c7280a6b +SIZE (smlnj/110.76/ml-lpt.tgz) = 256293 +SHA256 (smlnj/110.76/ml-lpt.tgz) = 9970b22506a605012055700cc28497c2850d29fbb7bcc5b069fbef785220fc8d +SHA256 (smlnj/110.76/ml-yacc.tgz) = 9151f7fef0abcb312daf731621b682b2c7e9f87a151832e99c30b5e56f03f1cf +SIZE (smlnj/110.76/ml-yacc.tgz) = 99943 +SHA256 (smlnj/110.76/nlffi.tgz) = 07bdc123b2c93f01bc0a5bbdf33aac0b34407bd70cd8d3e1d06ad55e92deb521 +SIZE (smlnj/110.76/nlffi.tgz) = 74484 +SIZE (smlnj/110.76/pgraph.tgz) = 5440 +SHA256 (smlnj/110.76/pgraph.tgz) = df44036b170f68a79a62134812adecd54c3f0da2188f0190996fc57faa10969c +SIZE (smlnj/110.76/runtime.tgz) = 324373 +SHA256 (smlnj/110.76/runtime.tgz) = f6086cd4e30ea3a89c528ee08c793eca77f7701589e0436acf347faf7e940a7f +SHA256 (smlnj/110.76/smlnj-c.tgz) = 0cdf1c3563f3080dffc184e8e64f5e58f7f21f1426d43cb8960cf090e2232a6f +SIZE (smlnj/110.76/smlnj-c.tgz) = 10534 +SIZE (smlnj/110.76/smlnj-lib.tgz) = 402937 +SHA256 (smlnj/110.76/smlnj-lib.tgz) = 81e994a07d7c8979b28c4911272de3c37eec648e58c03a9dc1ecb9bbbadca1d7 +SIZE (smlnj/110.76/system.tgz) = 227685 +SHA256 (smlnj/110.76/system.tgz) = 8f6a143db22a9d025e2820899c9cccbf0e66c679a9aa68c3dcd1bec68003da37 +SHA256 (smlnj/110.76/trace-debug-profile.tgz) = 3769e1d251d04c95b4c1b759f3bf21644bcb3135404d0346e8ff34553ae704df +SIZE (smlnj/110.76/trace-debug-profile.tgz) = 3899 Added: head/lang/smlnj/files/do-patch-base_runtime_objs_makefile ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/lang/smlnj/files/do-patch-base_runtime_objs_makefile Wed Jul 30 19:42:50 2014 (r363509) @@ -0,0 +1,43 @@ +--- base/runtime/objs/makefile.orig 2012-04-18 02:28:08.000000000 +0200 ++++ base/runtime/objs/makefile 2014-06-30 20:25:38.000000000 +0200 +@@ -5,10 +5,10 @@ + + SHELL = /bin/sh + MAKE = make +-CC = cc +-CPP = /lib/cpp ++CC ?= cc ++CPP ?= /lib/cpp + LD_LIBS = +-AS = as ++AS ?= as + AR = ar + ARFLAGS = rcv + RANLIB = ranlib +@@ -38,7 +38,7 @@ + CLIB_DIR = $(ROOT_DIR)/c-libs + CONFIG_DIR = $(ROOT_DIR)/config + +-CFLAGS = -O ++CFLAGS ?= -O + + INCLUDES = -I$(OBJS_DIR) -I$(INC_DIR) + GC_INCLUDES = $(INCLUDES) -I$(GC_DIR) +@@ -329,7 +329,7 @@ + # + MK_ARGS = VERSION="$(VERSION)" \ + MAKE="$(MAKE)" \ +- CC="$(CC)" CFLAGS="$(CFLAGS)" DEFS="$(DEFS)" \ ++ CC="$(CC)" CFLAGS="$(CFLAGS)" DEFS='$(DEFS)' \ + AR="$(AR)" ARFLAGS="$(ARFLAGS)" \ + RANLIB="$(RANLIB)" \ + INCLUDES="$(GC_INCLUDES) -I../bytecode" +@@ -420,7 +420,7 @@ + # + LIB_MK_ARGS = VERSION="$(VERSION)" \ + MAKE="$(MAKE)" \ +- CC="$(CC)" CFLAGS="$(CFLAGS)" DEFS="$(DEFS)" \ ++ CC="$(CC)" CFLAGS="$(CFLAGS)" DEFS='$(DEFS)' \ + AR="$(AR)" ARFLAGS="$(ARFLAGS)" \ + RANLIB="$(RANLIB)" \ + INCLUDES="$(LIB_INCLUDES)" Added: head/lang/smlnj/files/do-patch-base_runtime_objs_mk.x86-freebsd ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/lang/smlnj/files/do-patch-base_runtime_objs_mk.x86-freebsd Wed Jul 30 19:42:50 2014 (r363509) @@ -0,0 +1,37 @@ +--- base/runtime/objs/mk.x86-freebsd.orig 2006-04-20 17:28:53.000000000 +0200 ++++ base/runtime/objs/mk.x86-freebsd 2014-07-04 13:12:45.000000000 +0200 +@@ -5,19 +5,19 @@ + + SHELL = /bin/sh + +-MAKE = gmake ++MAKE = make + + ARFLAGS = Trcv +-CC = gcc -ansi +-CFLAGS = -O2 +-CPP = gcc -x assembler-with-cpp -E -P ++CC ?= gcc -ansi ++CFLAGS ?= -O2 ++CPP = ${CC} -x assembler-with-cpp -E -P + #CPP = /usr/bin/cpp -P + + XOBJS = + XLIBS = ../c-libs/dl/libunix-dynload.a + LD_LIBS = + BASE_DEFS = +-DEFS = $(BASE_DEFS) -DHOST_X86 -DTARGET_X86 -DOPSYS_UNIX -DOPSYS_FREEBSD -DDLOPEN ++DEFS = $(BASE_DEFS) -DHOST_X86 -DTARGET_X86 -DOPSYS_UNIX -DOPSYS_FREEBSD -DDLOPEN $(EXTRA_DEFS) + TARGET = X86 + VERSION = v-x86-freebsd + RUNTIME = run.x86-freebsd +@@ -25,6 +25,6 @@ + RUNTIME_A = run.x86-freebsd.a + + all: +- ($(MAKE) RUNTIME="$(RUNTIME)" VERSION="$(VERSION)" MAKE="$(MAKE)" CC="$(CC)" CFLAGS="$(CFLAGS)" CPP="$(CPP)" TARGET=$(TARGET) DEFS="$(DEFS)" XOBJS="$(XOBJS)" XLIBS="$(XLIBS)" LD_LIBS="$(LD_LIBS)" $(RUNTIME)) +- ($(MAKE) RUNTIME="$(RUNTIME_SO)" VERSION="$(VERSION)" MAKE="$(MAKE)" CC="$(CC)" CFLAGS="$(CFLAGS)" CPP="$(CPP)" TARGET=$(TARGET) DEFS="$(DEFS)" XOBJS="$(XOBJS)" XLIBS="$(XLIBS)" LD_LIBS="$(LD_LIBS)" LDFLAGS="-shared" $(RUNTIME_SO)) +- ($(MAKE) RUNTIME_A="$(RUNTIME_A)" VERSION="$(VERSION)" MAKE="$(MAKE)" CC="$(CC)" CFLAGS="$(CFLAGS)" CPP="$(CPP)" TARGET=$(TARGET) DEFS="$(DEFS)" XOBJS="$(XOBJS)" XLIBS="$(XLIBS)" LD_LIBS="$(LD_LIBS)" LDFLAGS="" $(RUNTIME_A)) ++ ($(MAKE) RUNTIME="$(RUNTIME)" VERSION="$(VERSION)" MAKE="$(MAKE)" AS="$(AS)" CC="$(CC)" CFLAGS="$(CFLAGS)" CPP="$(CPP)" TARGET=$(TARGET) DEFS="$(DEFS)" XOBJS="$(XOBJS)" XLIBS="$(XLIBS)" LD_LIBS="$(LD_LIBS)" $(RUNTIME)) ++ ($(MAKE) RUNTIME="$(RUNTIME_SO)" VERSION="$(VERSION)" MAKE="$(MAKE)" AS="$(AS)" CC="$(CC)" CFLAGS="$(CFLAGS)" CPP="$(CPP)" TARGET=$(TARGET) DEFS="$(DEFS)" XOBJS="$(XOBJS)" XLIBS="$(XLIBS)" LD_LIBS="$(LD_LIBS)" LDFLAGS="-shared" $(RUNTIME_SO)) ++ ($(MAKE) RUNTIME_A="$(RUNTIME_A)" VERSION="$(VERSION)" MAKE="$(MAKE)" AS="$(AS)" CC="$(CC)" CFLAGS="$(CFLAGS)" CPP="$(CPP)" TARGET=$(TARGET) DEFS="$(DEFS)" XOBJS="$(XOBJS)" XLIBS="$(XLIBS)" LD_LIBS="$(LD_LIBS)" LDFLAGS="" $(RUNTIME_A)) Added: head/lang/smlnj/files/extra-patch-base_runtime_c-libs_smlnj-math_ctlrndmode.c ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/lang/smlnj/files/extra-patch-base_runtime_c-libs_smlnj-math_ctlrndmode.c Wed Jul 30 19:42:50 2014 (r363509) @@ -0,0 +1,22 @@ +--- base/runtime/c-libs/smlnj-math/ctlrndmode.c.orig 2000-06-01 20:34:03.000000000 +0200 ++++ base/runtime/c-libs/smlnj-math/ctlrndmode.c 2013-06-18 15:08:01.715990633 +0200 +@@ -3,6 +3,19 @@ + * COPYRIGHT (c) 1996 AT&T Research. + */ + ++ #if defined(OPSYS_FREEBSD) ++ # if defined(INCLUDE_FREEBSD_I386__TYPES) ++ # include <sys/cdefs.h> ++ # include INCLUDE_FREEBSD_I386__TYPES ++ # endif ++ # if defined(INCLUDE_FREEBSD_I386_ENDIAN) ++ # include INCLUDE_FREEBSD_I386_ENDIAN ++ # endif ++ # if defined(INCLUDE_FREEBSD_I386_IEEEFP) ++ # include INCLUDE_FREEBSD_I386_IEEEFP ++ # endif ++ #endif ++ + #include "ml-base.h" + #include "fp-dep.h" + #include "ml-objects.h" Added: head/lang/smlnj/files/extra-patch-base_runtime_include_freebsd-8-i386-__types.h ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/lang/smlnj/files/extra-patch-base_runtime_include_freebsd-8-i386-__types.h Wed Jul 30 19:42:50 2014 (r363509) @@ -0,0 +1,137 @@ +--- base/runtime/include/freebsd-8-i386-_types.h.orig 1970-01-01 01:00:00.000000000 +0100 ++++ base/runtime/include/freebsd-8-i386-_types.h 2013-06-19 16:14:57.000000000 +0200 +@@ -0,0 +1,134 @@ ++/*- ++ * Copyright (c) 2002 Mike Barcroft <mike@FreeBSD.org> ++ * Copyright (c) 1990, 1993 ++ * The Regents of the University of California. All rights reserved. ++ * ++ * Redistribution and use in source and binary forms, with or without ++ * modification, are permitted provided that the following conditions ++ * are met: ++ * 1. Redistributions of source code must retain the above copyright ++ * notice, this list of conditions and the following disclaimer. ++ * 2. Redistributions in binary form must reproduce the above copyright ++ * notice, this list of conditions and the following disclaimer in the ++ * documentation and/or other materials provided with the distribution. ++ * 3. All advertising materials mentioning features or use of this software ++ * must display the following acknowledgement: ++ * This product includes software developed by the University of ++ * California, Berkeley and its contributors. ++ * 4. Neither the name of the University nor the names of its contributors ++ * may be used to endorse or promote products derived from this software ++ * without specific prior written permission. ++ * ++ * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND ++ * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE ++ * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ++ * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE ++ * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL ++ * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS ++ * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) ++ * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT ++ * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY ++ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF ++ * SUCH DAMAGE. ++ * ++ * From: @(#)ansi.h 8.2 (Berkeley) 1/4/94 ++ * From: @(#)types.h 8.3 (Berkeley) 1/5/94 ++ * $FreeBSD: stable/8/sys/i386/include/_types.h 176827 2008-03-05 11:21:14Z bde $ ++ */ ++ ++#ifndef _MACHINE__TYPES_H_ ++#define _MACHINE__TYPES_H_ ++ ++#ifndef _SYS_CDEFS_H_ ++#error this file needs sys/cdefs.h as a prerequisite ++#endif ++ ++#define __NO_STRICT_ALIGNMENT ++ ++/* ++ * Basic types upon which most other types are built. ++ */ ++typedef __signed char __int8_t; ++typedef unsigned char __uint8_t; ++typedef short __int16_t; ++typedef unsigned short __uint16_t; ++typedef int __int32_t; ++typedef unsigned int __uint32_t; ++ ++#if defined(lint) ++/* LONGLONG */ ++typedef long long __int64_t; ++/* LONGLONG */ ++typedef unsigned long long __uint64_t; ++#elif defined(__GNUCLIKE_ATTRIBUTE_MODE_DI) ++typedef int __attribute__((__mode__(__DI__))) __int64_t; ++typedef unsigned int __attribute__((__mode__(__DI__))) __uint64_t; ++#else ++/* LONGLONG */ ++typedef long long __int64_t; ++/* LONGLONG */ ++typedef unsigned long long __uint64_t; ++#endif ++ ++/* ++ * Standard type definitions. ++ */ ++typedef unsigned long __clock_t; /* clock()... */ ++typedef unsigned int __cpumask_t; ++typedef __int32_t __critical_t; ++typedef long double __double_t; ++typedef long double __float_t; ++typedef __int32_t __intfptr_t; ++typedef __int64_t __intmax_t; ++typedef __int32_t __intptr_t; ++typedef __int32_t __int_fast8_t; ++typedef __int32_t __int_fast16_t; ++typedef __int32_t __int_fast32_t; ++typedef __int64_t __int_fast64_t; ++typedef __int8_t __int_least8_t; ++typedef __int16_t __int_least16_t; ++typedef __int32_t __int_least32_t; ++typedef __int64_t __int_least64_t; ++typedef __int32_t __ptrdiff_t; /* ptr1 - ptr2 */ ++typedef __int32_t __register_t; ++typedef __int32_t __segsz_t; /* segment size (in pages) */ ++typedef __uint32_t __size_t; /* sizeof() */ ++typedef __int32_t __ssize_t; /* byte count or error */ ++typedef __int32_t __time_t; /* time()... */ ++typedef __uint32_t __uintfptr_t; ++typedef __uint64_t __uintmax_t; ++typedef __uint32_t __uintptr_t; ++typedef __uint32_t __uint_fast8_t; ++typedef __uint32_t __uint_fast16_t; ++typedef __uint32_t __uint_fast32_t; ++typedef __uint64_t __uint_fast64_t; ++typedef __uint8_t __uint_least8_t; ++typedef __uint16_t __uint_least16_t; ++typedef __uint32_t __uint_least32_t; ++typedef __uint64_t __uint_least64_t; ++typedef __uint32_t __u_register_t; ++typedef __uint32_t __vm_offset_t; ++typedef __int64_t __vm_ooffset_t; ++#ifdef PAE ++typedef __uint64_t __vm_paddr_t; ++#else ++typedef __uint32_t __vm_paddr_t; ++#endif ++typedef __uint64_t __vm_pindex_t; ++typedef __uint32_t __vm_size_t; ++ ++/* ++ * Unusual type definitions. ++ */ ++#ifdef __GNUCLIKE_BUILTIN_VARARGS ++typedef __builtin_va_list __va_list; /* internally known to gcc */ ++#else ++typedef char * __va_list; ++#endif /* __GNUCLIKE_BUILTIN_VARARGS */ ++#if defined(__GNUC_VA_LIST_COMPATIBILITY) && !defined(__GNUC_VA_LIST) \ ++ && !defined(__NO_GNUC_VA_LIST) ++#define __GNUC_VA_LIST ++typedef __va_list __gnuc_va_list; /* compatibility w/GNU headers*/ ++#endif ++ ++#endif /* !_MACHINE__TYPES_H_ */ Added: head/lang/smlnj/files/extra-patch-base_runtime_include_freebsd-8-i386-endian.h ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/lang/smlnj/files/extra-patch-base_runtime_include_freebsd-8-i386-endian.h Wed Jul 30 19:42:50 2014 (r363509) @@ -0,0 +1,139 @@ +--- base/runtime/include/freebsd-8-i386-endian.h.orig 1970-01-01 01:00:00.000000000 +0100 ++++ base/runtime/include/freebsd-8-i386-endian.h 2013-06-19 16:14:56.000000000 +0200 +@@ -0,0 +1,136 @@ ++/*- ++ * Copyright (c) 1987, 1991 Regents of the University of California. ++ * All rights reserved. ++ * ++ * Redistribution and use in source and binary forms, with or without ++ * modification, are permitted provided that the following conditions ++ * are met: ++ * 1. Redistributions of source code must retain the above copyright ++ * notice, this list of conditions and the following disclaimer. ++ * 2. Redistributions in binary form must reproduce the above copyright ++ * notice, this list of conditions and the following disclaimer in the ++ * documentation and/or other materials provided with the distribution. ++ * 4. Neither the name of the University nor the names of its contributors ++ * may be used to endorse or promote products derived from this software ++ * without specific prior written permission. ++ * ++ * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND ++ * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE ++ * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ++ * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE ++ * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL ++ * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS ++ * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) ++ * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT ++ * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY ++ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF ++ * SUCH DAMAGE. ++ * ++ * @(#)endian.h 7.8 (Berkeley) 4/3/91 ++ * $FreeBSD: stable/8/sys/i386/include/endian.h 190854 2009-04-08 19:10:20Z ed $ ++ */ ++ ++#ifndef _MACHINE_ENDIAN_H_ ++#define _MACHINE_ENDIAN_H_ ++ ++#include <sys/cdefs.h> ++#include <sys/_types.h> ++ ++#ifdef __cplusplus ++extern "C" { ++#endif ++ ++/* ++ * Define the order of 32-bit words in 64-bit words. ++ */ ++#define _QUAD_HIGHWORD 1 ++#define _QUAD_LOWWORD 0 ++ ++/* ++ * Definitions for byte order, according to byte significance from low ++ * address to high. ++ */ ++#define _LITTLE_ENDIAN 1234 /* LSB first: i386, vax */ ++#define _BIG_ENDIAN 4321 /* MSB first: 68000, ibm, net */ ++#define _PDP_ENDIAN 3412 /* LSB first in word, MSW first in long */ ++ ++#define _BYTE_ORDER _LITTLE_ENDIAN ++ ++/* ++ * Deprecated variants that don't have enough underscores to be useful in more ++ * strict namespaces. ++ */ ++#if __BSD_VISIBLE ++#define LITTLE_ENDIAN _LITTLE_ENDIAN ++#define BIG_ENDIAN _BIG_ENDIAN ++#define PDP_ENDIAN _PDP_ENDIAN ++#define BYTE_ORDER _BYTE_ORDER ++#endif ++ ++#if defined(__GNUCLIKE_ASM) && defined(__GNUCLIKE_BUILTIN_CONSTANT_P) ++ ++#define __byte_swap_int_var(x) \ ++__extension__ ({ register __uint32_t __X = (x); \ ++ __asm ("bswap %0" : "+r" (__X)); \ ++ __X; }) ++ ++#ifdef __OPTIMIZE__ ++ ++#define __byte_swap_int_const(x) \ ++ ((((x) & 0xff000000) >> 24) | \ ++ (((x) & 0x00ff0000) >> 8) | \ ++ (((x) & 0x0000ff00) << 8) | \ ++ (((x) & 0x000000ff) << 24)) ++#define __byte_swap_int(x) (__builtin_constant_p(x) ? \ ++ __byte_swap_int_const(x) : __byte_swap_int_var(x)) ++ ++#else /* __OPTIMIZE__ */ ++ ++#define __byte_swap_int(x) __byte_swap_int_var(x) ++ ++#endif /* __OPTIMIZE__ */ ++ ++static __inline __uint64_t ++__bswap64(__uint64_t _x) ++{ ++ ++ return ((_x >> 56) | ((_x >> 40) & 0xff00) | ((_x >> 24) & 0xff0000) | ++ ((_x >> 8) & 0xff000000) | ((_x << 8) & ((__uint64_t)0xff << 32)) | ++ ((_x << 24) & ((__uint64_t)0xff << 40)) | ++ ((_x << 40) & ((__uint64_t)0xff << 48)) | ((_x << 56))); ++} ++ ++static __inline __uint32_t ++__bswap32(__uint32_t _x) ++{ ++ ++ return (__byte_swap_int(_x)); ++} ++ ++static __inline __uint16_t ++__bswap16(__uint16_t _x) ++{ ++ return (_x << 8 | _x >> 8); ++} ++ ++#define __htonl(x) __bswap32(x) ++#define __htons(x) __bswap16(x) ++#define __ntohl(x) __bswap32(x) ++#define __ntohs(x) __bswap16(x) ++ ++#else /* !(__GNUCLIKE_ASM && __GNUCLIKE_BUILTIN_CONSTANT_P) */ ++ ++/* ++ * No optimizations are available for this compiler. Fall back to ++ * non-optimized functions by defining the constant usually used to prevent ++ * redefinition. ++ */ ++#define _BYTEORDER_FUNC_DEFINED ++ ++#endif /* __GNUCLIKE_ASM && __GNUCLIKE_BUILTIN_CONSTANT_P */ ++ ++#ifdef __cplusplus ++} ++#endif ++ ++#endif /* !_MACHINE_ENDIAN_H_ */ Added: head/lang/smlnj/files/extra-patch-base_runtime_include_freebsd-8-i386-ieeefp.h ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/lang/smlnj/files/extra-patch-base_runtime_include_freebsd-8-i386-ieeefp.h Wed Jul 30 19:42:50 2014 (r363509) @@ -0,0 +1,262 @@ +--- base/runtime/include/freebsd-8-i386-ieeefp.h.orig 1970-01-01 01:00:00.000000000 +0100 ++++ base/runtime/include/freebsd-8-i386-ieeefp.h 2013-06-19 16:14:57.000000000 +0200 +@@ -0,0 +1,259 @@ ++/*- ++ * Copyright (c) 2003 Peter Wemm. ++ * Copyright (c) 1990 Andrew Moore, Talke Studio ++ * All rights reserved. ++ * ++ * Redistribution and use in source and binary forms, with or without ++ * modification, are permitted provided that the following conditions ++ * are met: ++ * 1. Redistributions of source code must retain the above copyright ++ * notice, this list of conditions and the following disclaimer. ++ * 2. Redistributions in binary form must reproduce the above copyright ++ * notice, this list of conditions and the following disclaimer in the ++ * documentation and/or other materials provided with the distribution. ++ * 3. All advertising materials mentioning features or use of this software ++ * must display the following acknowledgement: ++ * This product includes software developed by the University of ++ * California, Berkeley and its contributors. ++ * 4. Neither the name of the University nor the names of its contributors ++ * may be used to endorse or promote products derived from this software ++ * without specific prior written permission. ++ * ++ * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND ++ * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE ++ * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ++ * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE ++ * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL ++ * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS ++ * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) ++ * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT ++ * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY ++ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF ++ * SUCH DAMAGE. ++ * ++ * from: @(#) ieeefp.h 1.0 (Berkeley) 9/23/93 ++ * $FreeBSD: stable/8/sys/i386/include/ieeefp.h 175234 2008-01-11 18:59:35Z bde $ ++ */ ++ ++#ifndef _MACHINE_IEEEFP_H_ ++#define _MACHINE_IEEEFP_H_ ++ ++/* ++ * IEEE floating point type, constant and function definitions. ++ * XXX: FP*FLD and FP*OFF are undocumented pollution. ++ */ ++ ++#ifndef _SYS_CDEFS_H_ ++#error this file needs sys/cdefs.h as a prerequisite ++#endif ++ ++/* ++ * Rounding modes. ++ */ ++typedef enum { ++ FP_RN=0, /* round to nearest */ ++ FP_RM, /* round down towards minus infinity */ ++ FP_RP, /* round up towards plus infinity */ ++ FP_RZ /* truncate */ ++} fp_rnd_t; ++ ++/* ++ * Precision (i.e., rounding precision) modes. ++ */ ++typedef enum { ++ FP_PS=0, /* 24 bit (single-precision) */ ++ FP_PRS, /* reserved */ ++ FP_PD, /* 53 bit (double-precision) */ ++ FP_PE /* 64 bit (extended-precision) */ ++} fp_prec_t; ++ ++#define fp_except_t int ++ ++/* ++ * Exception bit masks. ++ */ ++#define FP_X_INV 0x01 /* invalid operation */ ++#define FP_X_DNML 0x02 /* denormal */ *** DIFF OUTPUT TRUNCATED AT 1000 LINES ***
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201407301942.s6UJgpx1000840>