RT3959: Fix misleading comment
[openssl.git] / Makefile.org
index e9b49d9c8f8bead6ddec8450115c7d7f34c7351d..3e326c0759b3fc19003a3a540e4a6b55e54806f9 100644 (file)
@@ -481,25 +481,28 @@ TABLE: Configure Configurations/*.conf
 # would occur. Therefore the list of files is temporarily stored into a file
 # and read directly, requiring GNU-Tar. Call "make TAR=gtar dist" if the normal
 # tar does not support the --files-from option.
-tar:
+TAR_COMMAND=$(TAR) $(TARFLAGS) --files-from ../$(TARFILE).list \
+                              --owner openssl:0 --group openssl:0 \
+                              --transform 's|^|openssl-$(VERSION)/|' \
+                              -cvf -
+
+../$(TARFILE).list:
+       find * \! -name STATUS \! -name TABLE \! -name '*.o' \! -name '*.a' \
+              \! -name '*.so' \! -name '*.so.*'  \! -name 'openssl' \
+              \! -name '*test' \! -name '.#*' \! -name '*~' \
+           | sort > ../$(TARFILE).list
+
+tar: ../$(TARFILE).list
        find . -type d -print | xargs chmod 755
        find . -type f -print | xargs chmod a+r
        find . -type f -perm -0100 -print | xargs chmod a+x
-       find * \! -name STATUS \! -name TABLE | sort > ../$(TARFILE).list; \
-       $(TAR) $(TARFLAGS) --files-from ../$(TARFILE).list -cvf - | \
-       tardy --user_number=0  --user_name=openssl \
-             --group_number=0 --group_name=openssl \
-             --prefix=openssl-$(VERSION) - |\
-       gzip --best >../$(TARFILE).gz; \
-       rm -f ../$(TARFILE).list; \
+       $(TAR_COMMAND) | gzip --best >../$(TARFILE).gz
+       rm -f ../$(TARFILE).list
        ls -l ../$(TARFILE).gz
 
-tar-snap:
-       @$(TAR) $(TARFLAGS) -cvf - \
-               `find * \! -name STATUS \! -name TABLE \! -name '*.o' \! -name '*.a' \! -name '*.so' \! -name '*.so.*'  \! -name 'openssl' \! -name '*test' \! -name '.#*' \! -name '*~' | sort` |\
-       tardy --user_number=0  --user_name=openssl \
-             --group_number=0 --group_name=openssl \
-             --prefix=openssl-$(VERSION) - > ../$(TARFILE);\
+tar-snap: ../$(TARFILE).list
+       $(TAR_COMMAND) > ../$(TARFILE)
+       rm -f ../$(TARFILE).list
        ls -l ../$(TARFILE)
 
 dist: