# Makefile for xv - Solaris # ----------------------------------------- # Created by E. Lassauge - Dec 2003 # ----------------------------------------- # your C compiler (and options) of choice # CC = cc CC = gcc -O4 -fno-strength-reduce # use this if you're using 'cc' on a DEC Alpha (OSF/1) or MIPS (Ultrix) system: # CC = cc -std1 -Olimit 750 # this is what I personally use on an OSF Alpha. Not that I recommend it. # CC = gcc -g -ansi -pedantic -W -Wreturn-type -Wmissing-prototypes \ # -Wstrict-prototypes -Waggregate-return -Wconversion \ # -Wpointer-arith -Wcomment -Wformat -Wchar-subscripts \ # -Wuninitialized -Wparentheses CCOPTS = -I/usr/openwin/include -L/usr/openwin/lib ### Installation locations prefix = $(HOME)/.lassauge BINDIR = $(prefix)/bin MANDIR = $(prefix)/man/man1 MANSUF = 1x LIBDIR = $(prefix)/lib mkinstalldirs = $(SHELL) ./mkinstalldirs buildit: all ########################### CONFIGURATION OPTIONS ############################ ### NOTE: be sure to check 'config.h', for a few other configuration options ############################################################################## JPEG = -DDOJPEG -I/usr/local/include TIFF = PNG = -DDOPNG -I/usr/local/include GZLIB = -L/usr/local/lib -lz PNGLIB = -L/usr/local/lib -lpng JPEGLIB = -L/usr/local/lib -ljpeg TIFFLIB = #----------Machine Specific Configurations---------- MCHN = -DSolaris -DSOLARIS #----------'Roll Your Own' Options---------- # if your machine doesn't have 'random()', but does have 'rand()', # uncomment the following line: # #RAND = -DNO_RANDOM # if your system *doesn't* have /usr/include/dirent.h, (ie, isn't POSIX # compliant, then you may have to uncomment the following line to use the # 'old-style' directory-handling structures # #NODIRENT = -DNODIRENT # if your machine has the usleep() function, uncomment the following line: # if it doesn't, or you're not sure, leave this line alone. TIMERS = -DUSLEEP # if XV locks up whenever you click on *any* of the buttons, the Timer() # function in xvmisc.c is going out to lunch. A simple workaround is to # uncomment the following line: #TIMERS = -DNOTIMER # if you are running under DXWM, I pity you. XV doesn't work correctly # under DXWM. You should probably be running MWM. However, if such is # not an option for you, try uncommenting the following line. The # behavior won't be 'right', but it will be less 'wrong'. #DXWM = -DDXWM # if, during compilation, your system complains about the types # 'u_long', 'u_short', 'u_int', etc. as being undefined, uncomment the # following line: #BSDTYPES = -DBSDTYPES # if your machine doesn't have 'vprintf()' or 'vsprintf()' # (see vprintf.c for more information, if needed) # # (for BSD 4.3 VAX, uncomment the following line) #VPRINTF = -DNEED_VPRINTF -DINTSPRINTF -DLONGINT -DNOVOID # (for (stock) IBM RT AOS 4.3, uncomment the following line) #VPRINTF = -DNEED_VPRINTF -DLONGINT -DNOSTDHDRS # (for Sequent running DYNIX 3.1.4, uncomment the following line) #VPRINTF = -DNEED_VPRINTF -DLONGINT -DNOSTDHDRS ################ END OF CONFIGURATION OPTIONS ################# INSTALL = /usr/ucb/install -c -m 0755 CFLAGS = $(CCOPTS) $(JPEG) $(PNG) $(TIFF) $(PDS) \ $(NODIRENT) $(VPRINTF) $(TIMERS) $(UNIX) $(BSDTYPES) $(RAND) \ $(DXWM) $(MCHN) -DUSE_GETCWD LIBS = -lX11 -lm IMLIBS = -lX11 $(JPEGLIB) $(TIFFLIB) $(PNGLIB) $(GZLIB) -lm OBJS = xv.o xvevent.o xvroot.o xvmisc.o xvimage.o xvcolor.o xvsmooth.o \ xv24to8.o xvgif.o xvpm.o xvinfo.o xvctrl.o xvscrl.o xvalg.o \ xvgifwr.o xvdir.o xvbutt.o xvpbm.o xvxbm.o xvgam.o xvbmp.o \ xvdial.o xvgraf.o xvsunras.o xvjpeg.o xvps.o xvpopup.o xvdflt.o \ xvtiff.o xvtiffwr.o xvpds.o xvrle.o xviris.o xvgrab.o vprintf.o \ xvbrowse.o xvtext.o xvpcx.o xviff.o xvtarga.o xvxpm.o xvcut.o \ xvxwd.o xvfits.o xvpng.o MISC = README INSTALL CHANGELOG IDEAS cleandir .c.o: ; $(CC) $(CFLAGS) -c $*.c all: xv bggen vdcomp xcmap xvpictoppm xv: $(OBJS) $(CC) -o xv $(CFLAGS) $(OBJS) $(IMLIBS) bggen: bggen.c $(CC) $(CFLAGS) -o bggen bggen.c $(LIBS) vdcomp: vdcomp.c $(CC) $(CFLAGS) -o vdcomp vdcomp.c xcmap: xcmap.c $(CC) $(CFLAGS) -o xcmap xcmap.c $(LIBS) xvpictoppm: xvpictoppm.c $(CC) $(CFLAGS) -o xvpictoppm xvpictoppm.c xvclean: rm -f $(OBJS) xv clean: xvclean rm -f bggen vdcomp xcmap xvpictoppm install: install.prog install.man install.prog: $(mkinstalldirs) $(BINDIR) @list='xv bggen vdcomp xcmap xvpictoppm'; for p in $$list; do \ if test -f $$p; then \ echo " $(INSTALL) $$p $(BINDIR)/`echo $$p|sed 's/$(EXEEXT)$$//'|sed '$(transform)'|sed 's/$$/$(EXEEXT)/'`"; \ $(INSTALL) $$p $(BINDIR)/`echo $$p|sed 's/$(EXEEXT)$$//'|sed '$(transform)'|sed 's/$$/$(EXEEXT)/'`; \ else :; fi; \ done install.man: $(mkinstalldirs) $(MANDIR) cp docs/xv.man $(MANDIR)/xv.$(MANSUF) cp docs/bggen.man $(MANDIR)/bggen.$(MANSUF) cp docs/xcmap.man $(MANDIR)/xcmap.$(MANSUF) cp docs/xvp2p.man $(MANDIR)/xvpictoppm.$(MANSUF) cp docs/vdcomp.man $(MANDIR)/vdcomp.$(MANSUF) install.doc: $(mkinstalldirs) $(LIBDIR)/xv cp docs/xvdocs.ps* $(LIBDIR)/xv tar: tar cvf xv.tar Makefile* Imakefile *.c *.h bits \ mkinstalldirs docs unsupt vms patches $(MISC) xvsrctar: (cd ..; \ tar cvjf xv-3.10a-EL-src.tar.bz2 xv-3.10a-EL/Makefile* xv-3.10a-EL/mkinstalldirs xv-3.10a-EL/Imakefile xv-3.10a-EL/*.c xv-3.10a-EL/*.h xv-3.10a-EL/bits xv-3.10a-EL/docs/*.man) $(OBJS): xv.h config.h ################# bitmap dependencies #################### xv.o: bits/icon bits/iconmask bits/runicon bits/runiconm xv.o: bits/cboard50 bits/gray25 xvbrowse.o: bits/br_file bits/br_dir bits/br_exe bits/br_chr bits/br_blk xvbrowse.o: bits/br_sock bits/br_fifo bits/br_error bits/br_unknown xvbrowse.o: bits/br_cmpres bits/br_gif bits/br_pm bits/br_pbm xvbrowse.o: bits/br_sunras bits/br_bmp bits/br_utah bits/br_iris xvbrowse.o: bits/br_pcx bits/br_jfif bits/br_tiff bits/br_pds xvbrowse.o: bits/br_ps bits/br_iff bits/br_targa bits/br_xpm xvbrowse.o: bits/br_trash bits/fcurs bits/fccurs bits/fdcurs bits/fcursm xvbrowse.o: bits/br_xwd bits/br_png bits/br_bzip2 xvbutt.o: bits/cboard50 bits/rb_frame bits/rb_frame1 bits/rb_top xvbutt.o: bits/rb_bot bits/rb_dtop bits/rb_dbot bits/rb_body xvbutt.o: bits/rb_dot bits/cb_check bits/mb_chk xvctrl.o: bits/gray25 bits/gray50 bits/i_fifo bits/i_chr bits/i_dir xvctrl.o: bits/i_blk bits/i_lnk bits/i_sock bits/i_exe bits/i_reg xvctrl.o: bits/h_rotl bits/h_rotr bits/fliph bits/flipv bits/p10 xvctrl.o: bits/m10 bits/cut bits/copy bits/paste bits/clear xvctrl.o: bits/uicon bits/oicon1 bits/oicon2 bits/icon xvctrl.o: bits/padimg bits/annot xvcut.o: bits/cut bits/cutm bits/copy bits/copym xvdflt.o: bits/logo_top bits/logo_bot bits/logo_out bits/xv_jhb xvdflt.o: bits/xv_cpyrt bits/xv_rev bits/xv_ver xvdflt.o: bits/xf_left bits/xf_right bits/font5x9.h xvdflt.o: xvdflt.h xvdial.o: bits/dial_cw1 bits/dial_ccw1 bits/dial_cw2 bits/dial_ccw2 xvdir.o: bits/d_load bits/d_save xvevent.o: bits/dropper bits/dropperm bits/pen bits/penm xvevent.o: bits/blur bits/blurm xvgam.o: bits/h_rotl bits/h_rotr bits/h_flip bits/h_sinc bits/h_sdec xvgam.o: bits/h_sat bits/h_desat xvgraf.o: bits/gf1_addh bits/gf1_delh bits/gf1_line bits/gf1_spln xvgraf.o: bits/gf1_rst bits/gf1_gamma xvinfo.o: bits/penn bits/pennnet xvmisc.o: bits/fc_left bits/fc_leftm bits/fc_left1 bits/fc_left1m xvmisc.o: bits/fc_mid bits/fc_midm bits/fc_right1 bits/fc_right1m xvmisc.o: bits/fc_right bits/fc_rightm xvpopup.o: bits/icon xvroot.o: bits/root_weave xvscrl.o: bits/up bits/down bits/up1 bits/down1 bits/uph bits/downh xvscrl.o: bits/uph1 bits/downh1 bits/scrlgray ################# end bitmap dependencies ####################