timm / crusty

Automatically exported from code.google.com/p/crusty
0 stars 0 forks source link

trunk/Makefile: `make dist` fails #24

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
The `make dist` target fails due to an incorrect svn repository hard-coded
in the Makefile.

Additionally, the target utilizes '/tmp' to build the .zip file and doesn't
clean it up, which is a security risk and generally not a very nice thing
to do.

Original issue reported on code.google.com by david.a....@gmail.com on 17 Jan 2007 at 6:25

GoogleCodeExporter commented 9 years ago
Replaced svn repository with 'revision 30', `make dist` builds the crusty.zip
distributable file.

Target still does not clean up after itself and still utilizes /tmp (though I'm 
not
sure exactly why it bothers with /tmp/crustyzip).

Original comment by david.a....@gmail.com on 17 Jan 2007 at 6:59

GoogleCodeExporter commented 9 years ago
The use of temp can be fixed by ensuring that the file is created with the 
proper
permissions and ensure that it does not exist before we create it.  It might be
easier to create a temporary directory.  man mktemp for some info on how to do 
a poor
man's mktemp.  Unless someone wants to create a proper configure script and 
check for
mktemp.

Original comment by scott.he...@gmail.com on 19 Jan 2007 at 4:30

GoogleCodeExporter commented 9 years ago
My vote is to create some directory (eg. temp, build, stage, or something) in 
the
current directory. We refer to it as the variable TEMP in the Makefile. If the 
user
really wants to build to someplace outside home or on another partition, he can
override it with `make TEMP=/tmp`. 

We can then tell subversion to ignore this staging directory by doing `echo 
temp >
.svnignore && vn propset svn:ignore -F .svnignore .`

Added bonus is that `make clean` just needs to `rm -rf $(TEMP)`.

Original comment by david.a....@gmail.com on 19 Jan 2007 at 5:28

GoogleCodeExporter commented 9 years ago
I added david's rule. snownews now uses a $(Tmp) macri

Original comment by menzies....@gmail.com on 4 Feb 2007 at 2:45