On 03/10/09 09:55, Cristian Rodríguez wrote:
On 03/10/09 09:26, doiggl@velocitynet.com.au wrote:
- Question: What other entries do i need in the make file to do the compile ?
There are many ways to solve your problem, I will suggest you two of them
- during %install use %{__install} utility to put the bw binary in %{buildroot}%{_bindir}
- You can use the following "Cmake" script to replace the makefile
save as CMakeLists.txt
PROJECT(bwgraph C) SET(CMAKE_VERBOSE_MAKEFILE ON) ADD_EXECUTABLE(bw bw.c) INSTALL(PROGRAMS bw DESTINATION bin)
now you have an "install" target.. however your story does not end there, "bwbar" is meant to be an init script, see Packaging Guidelines to know how to convert it to a proper init script.
Also, note this harcoded stuff in bw.c /* note that file is converted to pnm 2x the desired size so pnmscale can antialias */ static char *convert_ps2pnm = "gs -q -r144 -sOutputFile=/tmp/bw.pnm -sDEVICE=pnm -dBATCH -dNOPAUSE /tmp/bw.ps"; static char *convert_pnm2png = "pnmscale 0.5 -quiet /tmp/bw.pnm | pnmtopng -quiet >/tmp/bw.png"; static char *convert_ps2pdf = "ps2pdf14 /tmp/bw.ps /tmp/bw.pdf"; static char *movecmd = "cp -f /tmp/bw.png /home/httpd/html/bw-%s.png ; cp -f /tmp/bw.pdf /home/httpd/html/bw-%s.pdf"; Looks like that you certainly: - Dont want that ;-) - It will race. - you need to Require those tools in the spec file. -- To unsubscribe, e-mail: opensuse-packaging+unsubscribe@opensuse.org For additional commands, e-mail: opensuse-packaging+help@opensuse.org