[Bio] / FigCommon / Makefile Repository:
ViewVC logotype

Annotation of /FigCommon/Makefile

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.16 - (view) (download)

1 : efrank 1.1 #
2 : olson 1.14 # Copyright (c) 2003-2006 University of Chicago and Fellowship
3 :     # for Interpretations of Genomes. All Rights Reserved.
4 :     #
5 :     # This file is part of the SEED Toolkit.
6 : parrello 1.15 #
7 : olson 1.14 # The SEED Toolkit is free software. You can redistribute
8 :     # it and/or modify it under the terms of the SEED Toolkit
9 : parrello 1.15 # Public License.
10 : olson 1.14 #
11 :     # You should have received a copy of the SEED Toolkit Public License
12 :     # along with this program; if not write to the University of Chicago
13 :     # at info@ci.uchicago.edu or the Fellowship for Interpretation of
14 :     # Genomes at veronika@thefig.info or download a copy from
15 :     # http://www.theseed.org/LICENSE.TXT.
16 :     #
17 :    
18 :     #
19 : efrank 1.1 #
20 :     #
21 :    
22 : olson 1.10 BINSCRIPTS := configure-env switch_to_release make_sandbox tool_hdr tool_hdr_py \
23 : olson 1.13 setup-sge sge-daemons lwc_postprocess
24 : olson 1.5 PERLPACKAGES := $(wildcard *.pm)
25 : efrank 1.1
26 : parrello 1.15 lib: $(foreach var, $(PERLPACKAGES), $(libdir)/$(PKGNAME)/$(var))
27 : efrank 1.1
28 :     bin: $(foreach var, $(BINSCRIPTS), $(bindir)/$(var))
29 :    
30 : olson 1.9 schematools:
31 : olson 1.11 stDeclFiles:
32 :     stGeneratedFiles:
33 :    
34 : olson 1.12 #
35 :     # Machinery to fix perl's Config.pm to have the correct paths
36 :     # for this installation of the SEED environment - we may be
37 :     # running in a directory other than that the perl was compiled for.
38 :     #
39 :    
40 : olson 1.16 PERL = $(shell sed -ne 's/^RTPERL=\(.*\)/\1/p' $(RTROOT)/config/RTConfig)
41 :     #PERL = $(RTROOT)/env/$(RTARCH)/bin/perl
42 : olson 1.12
43 :     #
44 :     # Determine the architecture name and version for the SEED environment perl.
45 :     #
46 :    
47 :     PERL_ARCH = $(shell $(PERL) -e 'use Config; print $$Config{archname}')
48 :     PERL_VERS = $(shell $(PERL) -e 'use Config; print $$Config{version}')
49 :    
50 :     #
51 :     # Use these to determine the directory in which Config.pm is located.
52 :     #
53 :     PERL_ARCH_LIB = $(RTROOT)/env/$(RTARCH)/lib/perl5/$(PERL_VERS)/$(PERL_ARCH)
54 :     PERL_CONFIG_DIST = $(PERL_ARCH_LIB)/Config.pm.dist
55 :     PERL_CONFIG = $(PERL_ARCH_LIB)/Config.pm
56 :    
57 :     #
58 :     # The SEED environment has a file PREFIX that declares the location
59 :     # to which the environment was installed at compilation time.
60 :     #
61 :     PERL_INST_PREFIX = $(shell cat $(RTROOT)/env/$(RTARCH)/PREFIX)
62 :    
63 :     #
64 :     # Fix Config.pm by replacing the install prefix with the current location.
65 :     #
66 :    
67 :     fix_perl_configpm: $(PERL_CONFIG_DIST)
68 :     chmod +w $(PERL_CONFIG)
69 :     sed -e 's,$(PERL_INST_PREFIX),$(RTROOT)/env/$(RTARCH),g' < $(PERL_CONFIG_DIST) > $(PERL_CONFIG)
70 :     chmod -w $(PERL_CONFIG)
71 :     touch fix_perl_configpm
72 :    
73 :     #
74 :     # Copy the original Config.pm to Config.pm.dist if we haven't done so before.
75 :     #
76 :    
77 :     $(PERL_CONFIG_DIST): $(PERL_CONFIG)
78 :     if [ ! -f $(PERL_CONFIG_DIST) ] ; then \
79 :     cp $(PERL_CONFIG) $(PERL_CONFIG_DIST); \
80 :     fi
81 :     chmod +w $(PERL_CONFIG)
82 :     chmod -w $(PERL_CONFIG_DIST)
83 :     touch $(PERL_CONFIG_DIST)
84 :     chmod +w $(PERL_CONFIG_DIST)
85 : olson 1.9
86 : efrank 1.2 test:
87 :    
88 :     clean:
89 : olson 1.12 -rm fix_perl_configpm
90 : efrank 1.1
91 :     $(bindir)/%: $(TOPDIR)/$(PKGNAME)/%
92 : parrello 1.15 cp $< $(bindir)/.
93 : efrank 1.3
94 :     $(bindir)/%: $(TOPDIR)/$(PKGNAME)/%.pl $(TOOL_HDR)
95 :     ( cat $(TOOL_HDR) $< > $@; chmod +x $@ )
96 : olson 1.5
97 :     $(libdir)/$(PKGNAME)/%.pm: $(TOPDIR)/$(PKGNAME)/%.pm
98 : parrello 1.15 cp $< $@
99 : efrank 1.1

MCS Webmaster
ViewVC Help
Powered by ViewVC 1.0.3