This is the mail archive of the cygwin-apps@cygwin.com mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[PATCH] generic build script


Hello Igor,


found it useful (I want to build LibJasper which is only available as
zipped archive):

--- gbs~        2004-06-08 16:56:20.215388800 +0200
+++ gbs 2004-06-08 16:42:53.791884800 +0200
@@ -53,6 +53,9 @@
 elif [ -e ${BASEPKG}.tar ] ; then
   export opt_decomp=
   export src_orig_pkg_name=${BASEPKG}.tar
+elif [ -e ${BASEPKG}.zip ] ; then
+  export opt_decomp=zip
+  export src_orig_pkg_name=${BASEPKG}.zip
 else
   echo Cannot find original package.
   exit 1
@@ -116,7 +119,11 @@
 # change this if the original package was not tarred
 # or if it doesn't unpack to a correct directory
 unpack() {
-  tar xv${opt_decomp}f "$1"
+  if [ "x"$opt_decomp = "xzip" ] ; then \
+    unzip "$1" ; \
+  else \
+    tar xv${opt_decomp}f "$1" ; \
+  fi
 }
 
 mkdirs() {


Gerrit
-- 
=^..^=


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]