Permalink
Browse files

Fixes #2084. Makeify tools/osx-dist.sh

  • Loading branch information...
1 parent 61e796d commit 9d1bdbcf05c9f23a9e18caccf305cf63b563c3b8 @ry ry committed Nov 21, 2011
Showing with 15 additions and 32 deletions.
  1. +14 −3 Makefile
  2. +0 −28 tools/osx-dist.sh
  3. +1 −1 tools/osx-pkg.pmdoc/01local.xml
View
17 Makefile
@@ -132,14 +132,25 @@ check:
VERSION=v$(shell python tools/getnodeversion.py)
TARNAME=node-$(VERSION)
TARBALL=$(TARNAME).tar.gz
-PKG=dist-osx/$(TARNAME).pkg
+PKG=out/$(TARNAME).pkg
+
+packagemaker=/Developer/Applications/Utilities/PackageMaker.app/Contents/MacOS/PackageMaker
#dist: doc/node.1 doc/api
dist: $(TARBALL) $(PKG)
+PKGDIR=out/dist-osx
+
+pkg: $(PKG)
+
$(PKG):
- -rm -rf dist-osx
- tools/osx-dist.sh
+ -rm -rf $(PKGDIR)
+ $(WAF) configure --prefix=/usr/local
+ DESTDIR=$(PKGDIR) $(WAF) install
+ $(packagemaker) \
+ --id "org.nodejs.NodeJS-$(VERSION)" \
+ --doc tools/osx-pkg.pmdoc \
+ --out $(PKG)
$(TARBALL): out/doc
git archive --format=tar --prefix=$(TARNAME)/ HEAD | tar xf -
View
28 tools/osx-dist.sh
@@ -1,28 +0,0 @@
-#!/bin/sh
-
-TOOLS=`dirname $0`
-ROOT=$TOOLS/..
-
-VERSION=`python $TOOLS/getnodeversion.py`
-CONTENTS=$ROOT/dist-osx
-PMDOC=$TOOLS/osx-pkg.pmdoc
-VENDOR='org.nodejs'
-NAME=NodeJS
-
-# go build it in the root of the git repository
-pushd $ROOT
-
-./configure --prefix=/usr/local
-make
-make install DESTDIR="$CONTENTS"
-
-popd # $ROOT
-
-PKGID="$VENDOR.$NAME-$VERSION"
-
-packagemaker=/Developer/Applications/Utilities/PackageMaker.app/Contents/MacOS/PackageMaker
-
-$packagemaker \
- --id "$PKGID" \
- --doc $PMDOC \
- --out $CONTENTS/node-v$VERSION.pkg
View
2 tools/osx-pkg.pmdoc/01local.xml
@@ -1 +1 @@
-<pkgref spec="1.12" uuid="053587FE-BDF3-4EF5-815D-281427431048"><config><identifier>org.nodejs.pkg</identifier><version>1.0</version><description></description><post-install type="none"/><requireAuthorization/><installFrom relative="true" mod="true">../dist-osx/usr/local/</installFrom><installTo mod="true" relocatable="true">/usr/local</installTo><flags><followSymbolicLinks/></flags><packageStore type="internal"></packageStore><mod>installTo.isRelativeType</mod><mod>installTo</mod><mod>locationType</mod><mod>relocatable</mod><mod>installFrom.path</mod><mod>installTo.isAbsoluteType</mod><mod>identifier</mod><mod>parent</mod><mod>installTo.path</mod><mod>installFrom.isRelativeType</mod></config><contents><file-list>01local-contents.xml</file-list><filter>/CVS$</filter><filter>/\.svn$</filter><filter>/\.cvsignore$</filter><filter>/\.cvspass$</filter><filter>/\.DS_Store$</filter></contents></pkgref>
+<pkgref spec="1.12" uuid="053587FE-BDF3-4EF5-815D-281427431048"><config><identifier>org.nodejs.pkg</identifier><version>1.0</version><description></description><post-install type="none"/><requireAuthorization/><installFrom relative="true" mod="true">../out/dist-osx/usr/local/</installFrom><installTo mod="true" relocatable="true">/usr/local</installTo><flags><followSymbolicLinks/></flags><packageStore type="internal"></packageStore><mod>installTo.isRelativeType</mod><mod>installTo</mod><mod>locationType</mod><mod>relocatable</mod><mod>installFrom.path</mod><mod>installTo.isAbsoluteType</mod><mod>identifier</mod><mod>parent</mod><mod>installTo.path</mod><mod>installFrom.isRelativeType</mod></config><contents><file-list>01local-contents.xml</file-list><filter>/CVS$</filter><filter>/\.svn$</filter><filter>/\.cvsignore$</filter><filter>/\.cvspass$</filter><filter>/\.DS_Store$</filter></contents></pkgref>

0 comments on commit 9d1bdbc

Please sign in to comment.