Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

2007-06-19 Michal Ludvig <michal@logix.cz>

	* setup.py: Check for S3CMD_PACKAGING and don't install
	  manpages and docs if defined.
	* INSTALL: Document the above change.



git-svn-id: https://s3tools.svn.sourceforge.net/svnroot/s3tools/s3cmd/trunk@126 830e0280-6d2a-0410-9c65-932aecc39d9d
  • Loading branch information...
commit c99308640932a711f8bfa8b651acaabea6855f83 1 parent 49731b4
@mludvig mludvig authored
Showing with 31 additions and 6 deletions.
  1. +6 −0 ChangeLog
  2. +13 −0 INSTALL
  3. +12 −6 setup.py
View
6 ChangeLog
@@ -1,3 +1,9 @@
+2007-06-19 Michal Ludvig <michal@logix.cz>
+
+ * setup.py: Check for S3CMD_PACKAGING and don't install
+ manpages and docs if defined.
+ * INSTALL: Document the above change.
+
2007-06-17 Michal Ludvig <michal@logix.cz>
* s3cmd: Added encryption key support to --configure
View
13 INSTALL
@@ -66,6 +66,19 @@ There are three options to run s3cmd from source tarball:
find out the actual package name and how to install it then.
+Note to distibutions package maintainers
+----------------------------------------
+Define shell environment variable S3CMD_PACKAGING=yes if you
+don't want setup.py to install manpages and doc files. You'll
+have to install them manually in your .spec or similar package
+build scripts.
+
+On the other hand if you want setup.py to install manpages
+and docs, but to other than default path, define env
+variables $S3CMD_INSTPATH_MAN and $S3CMD_INSTPATH_DOC. Check
+out setup.py for details and default values.
+
+
Where to get help
-----------------
If in doubt, or if something doesn't work as expected,
View
18 setup.py
@@ -14,8 +14,17 @@
except:
pass
-man_path = os.getenv("S3CMD_INSTPATH_MAN") or "share/man"
-doc_path = os.getenv("S3CMD_INSTPATH_DOC") or "share/doc/packages"
+## Don't install manpages and docs when $S3CMD_PACKAGING is set
+## This was a requirement of Debian package maintainer.
+if not os.getenv("S3CMD_PACKAGING"):
+ man_path = os.getenv("S3CMD_INSTPATH_MAN") or "share/man"
+ doc_path = os.getenv("S3CMD_INSTPATH_DOC") or "share/doc/packages"
+ data_files = [
+ (doc_path+"/s3cmd", [ "README", "INSTALL", "NEWS" ]),
+ (man_path+"/man1", [ "s3cmd.1" ] ),
+ ]
+else:
+ data_files = None
## Main distutils info
setup(
@@ -24,10 +33,7 @@
version = S3.PkgInfo.version,
packages = [ 'S3' ],
scripts = ['s3cmd'],
- data_files = [
- (doc_path+"/s3cmd", [ "README", "INSTALL", "NEWS" ]),
- (man_path+"/man1", [ "s3cmd.1" ] ),
- ],
+ data_files = data_files,
## Packaging details
author = "Michal Ludvig",
Please sign in to comment.
Something went wrong with that request. Please try again.