[csw-devel] SF.net SVN: gar:[9997] csw/mgar/pkg/TEMPLATES/createpkg
theferret at users.sourceforge.net
theferret at users.sourceforge.net
Wed May 26 19:06:28 CEST 2010
Revision: 9997
http://gar.svn.sourceforge.net/gar/?rev=9997&view=rev
Author: theferret
Date: 2010-05-26 17:06:27 +0000 (Wed, 26 May 2010)
Log Message:
-----------
TEMPLATES/createpkg: improvements....
Modified Paths:
--------------
csw/mgar/pkg/TEMPLATES/createpkg/Makefile
csw/mgar/pkg/TEMPLATES/createpkg/copy_template
Modified: csw/mgar/pkg/TEMPLATES/createpkg/Makefile
===================================================================
--- csw/mgar/pkg/TEMPLATES/createpkg/Makefile 2010-05-26 16:01:01 UTC (rev 9996)
+++ csw/mgar/pkg/TEMPLATES/createpkg/Makefile 2010-05-26 17:06:27 UTC (rev 9997)
@@ -6,21 +6,30 @@
# in your top level src directory. It is also suitable for
# "relocateable" packages. see the createpkg docs for more details.
#CREATEPKG=createpkg -b `pwd`
-#CREATEPKG=createpkg -r .
-CREATEPKG=createpkg -r `pwd`/cswstage
+
+BUILDDIR=build/*
+
+CREATEPKG=createpkg -r `pwd`/build/*/cswstage
+
+
+STDFILES=pkginfo copyright prototype
+FILES=
+
package: $(STDFILE) $(FILES)
$(CREATEPKG)
- touch package
+
build:
- ./configure --prefix=/opt/csw
- $(MAKE)
- cswstage
+ (cd $(BUILDDIR) ; \
+ test -f ../../patchfile.preconf && \
+ gpatch -p0 <../../patchfile.preconf ; \
+ ./configure --prefix=/opt/csw ; \
+ test -f ../../patchfile.postconf && \
+ gpatch -p0 <../../patchfile.postconf ; \
+ $(MAKE) ; \
+ cswstage )
clean:
rm -f *.pkg.gz package
-STDFILES=pkginfo copyright prototype
-
-FILES=YourFilesHere
Modified: csw/mgar/pkg/TEMPLATES/createpkg/copy_template
===================================================================
--- csw/mgar/pkg/TEMPLATES/createpkg/copy_template 2010-05-26 16:01:01 UTC (rev 9996)
+++ csw/mgar/pkg/TEMPLATES/createpkg/copy_template 2010-05-26 17:06:27 UTC (rev 9997)
@@ -28,8 +28,8 @@
-$SVN info >/dev/null
-if [[ $? -ne 0 ]] ; then
+MY_SVN_DIR=`svn info| awk '$1=="URL:"{print $2}'`
+if [[ "$MY_SVN_DIR" == "" ]] ; then
print ERROR: expected to be within subversion tree somewhere
print cannot continue
exit 1
@@ -42,12 +42,14 @@
download
work
cswstage
+build
EOF
cp $template_dir/Makefile* $DESTDIR
cp $template_dir/prototype* $DESTDIR
$template_dir/generate_pkginfo >$DESTDIR/pkginfo
+print "OPENCSW_REPOSITORY=$MY_SVN_DIR/$DESTDIR" >>$DESTDIR/pkginfo
print ""
print Created directory $1 locally, and in subversion
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
More information about the devel
mailing list