Ticket #7667: Portfile

File Portfile, 8.2 KB (added by jtang@…, 18 years ago)

portfile for crm114 (see http://crm114.sf.net for more info on this tool)

Line 
1# $Id: $
2
3PortSystem 1.0
4name                    crm114
5version                 20060704a-BlameRobert
6categories              sysutils
7platforms               darwin
8maintainers             jtang@tchpc.tcd.ie
9description             Controllable Regex Mutilator 114
10long_description        CRM114 is a system to examine incoming e-mail, \
11                        system log streams, data files or other data \
12                        streams, and to sort, filter, or alter the incoming \
13                        files or data streams.
14
15homepage                http://crm114.sourceforge.net/
16master_sites            http://crm114.sourceforge.net/
17
18# no libtre
19#checksums              md5 7fec214c03679398979387b22e96b1d9
20#distname               ${name}-${version}.no-TRE.src
21
22# with libtre this seems better and more sane to debug
23# (though we still depend on libtre from the ports tree)
24checksums               md5 d019c7ac882c27b6b843fb2d2e4db274
25distname                ${name}-${version}.src
26depends_lib             port:libtre
27
28# override configure since crm114 doesnt come with autoconf/automake stuff
29configure    {}
30
31pre-build {
32        #
33        # use the BSD example as a basis for OSX
34        #
35        reinplace "s|prefix=/usr|prefix=${destroot}${prefix}|g" \
36                ${worksrcpath}/Makefile
37        reinplace "s|LDFLAGS += -static|#LDFLAGS += -static|g" \
38                ${worksrcpath}/Makefile
39        reinplace "s|#CFLAGS += -I/usr/local/include|CFLAGS += -I${prefix}/include|g" \
40                ${worksrcpath}/Makefile
41        reinplace "s|#LDFLAGS += -L/usr/local/lib|LDFLAGS += -L${prefix}/lib|g" \
42                ${worksrcpath}/Makefile
43        reinplace "s|#LIBS += -lintl -liconv|LIBS += -lintl -liconv|g" \
44                ${worksrcpath}/Makefile
45}
46
47post-destroot {
48        #
49        # create some directories, and copy the readme's etc... to the docs directory
50        # and copy the "examples", i hope i didnt miss anything since the original
51        # crm114 distro doesnt exactly say whats what for the scripts. not the
52        # cleverest of things to be doing since this will need to be done everytime
53        # the upstream author updates his package. but for now it works.
54        #
55        file mkdir ${destroot}${prefix}/share
56        file mkdir ${destroot}${prefix}/share/doc
57        file mkdir ${destroot}${prefix}/share/doc/crm114
58        file mkdir ${destroot}${prefix}/share/doc/crm114/examples
59
60        # copy the docs
61        file copy ${worksrcpath}/classify_details.txt ${destroot}${prefix}/share/doc/crm114
62        file copy ${worksrcpath}/COLOPHON.txt ${destroot}${prefix}/share/doc/crm114
63        file copy ${worksrcpath}/CRM114_Mailfilter_HOWTO.txt ${destroot}${prefix}/share/doc/crm114
64        file copy ${worksrcpath}/FAQ.txt ${destroot}${prefix}/share/doc/crm114
65        file copy ${worksrcpath}/GPL-License.txt ${destroot}${prefix}/share/doc/crm114
66        file copy ${worksrcpath}/inoc_passwd.txt ${destroot}${prefix}/share/doc/crm114
67        file copy ${worksrcpath}/INTRO.txt ${destroot}${prefix}/share/doc/crm114
68        file copy ${worksrcpath}/knownbugs.txt ${destroot}${prefix}/share/doc/crm114
69        file copy ${worksrcpath}/QUICKREF.txt ${destroot}${prefix}/share/doc/crm114
70        file copy ${worksrcpath}/things_to_do.txt ${destroot}${prefix}/share/doc/crm114
71
72        # copy all the scripts and docs *.crm and *.mfp
73        #
74        # for i in `ls *.crm`;
75        # do
76        #       echo "file copy \${worksrcpath}/$i \${destroot}\${prefix}/share/doc/crm114/examples"
77        # done
78        file copy ${worksrcpath}/aliustest.crm ${destroot}${prefix}/share/doc/crm114/examples
79        file copy ${worksrcpath}/approxtest.crm ${destroot}${prefix}/share/doc/crm114/examples
80        file copy ${worksrcpath}/argtest.crm ${destroot}${prefix}/share/doc/crm114/examples
81        file copy ${worksrcpath}/backwardstest.crm ${destroot}${prefix}/share/doc/crm114/examples
82        file copy ${worksrcpath}/beeptest.crm ${destroot}${prefix}/share/doc/crm114/examples
83        file copy ${worksrcpath}/bracktest.crm ${destroot}${prefix}/share/doc/crm114/examples
84        file copy ${worksrcpath}/call_return_test.crm ${destroot}${prefix}/share/doc/crm114/examples
85        file copy ${worksrcpath}/classifymail.crm ${destroot}${prefix}/share/doc/crm114/examples
86        file copy ${worksrcpath}/classifytest.crm ${destroot}${prefix}/share/doc/crm114/examples
87        file copy ${worksrcpath}/escapetest.crm ${destroot}${prefix}/share/doc/crm114/examples
88        file copy ${worksrcpath}/eval_infiniteloop.crm ${destroot}${prefix}/share/doc/crm114/examples
89        file copy ${worksrcpath}/exectest.crm ${destroot}${prefix}/share/doc/crm114/examples
90        file copy ${worksrcpath}/fataltraptest.crm ${destroot}${prefix}/share/doc/crm114/examples
91        file copy ${worksrcpath}/indirecttest.crm ${destroot}${prefix}/share/doc/crm114/examples
92        file copy ${worksrcpath}/inserttest_a.crm ${destroot}${prefix}/share/doc/crm114/examples
93        file copy ${worksrcpath}/inserttest_b.crm ${destroot}${prefix}/share/doc/crm114/examples
94        file copy ${worksrcpath}/inserttest_c.crm ${destroot}${prefix}/share/doc/crm114/examples
95        file copy ${worksrcpath}/isolate_reclaim_test.crm ${destroot}${prefix}/share/doc/crm114/examples
96        file copy ${worksrcpath}/learntest.crm ${destroot}${prefix}/share/doc/crm114/examples
97        file copy ${worksrcpath}/mailfilter.crm ${destroot}${prefix}/share/doc/crm114/examples
98        file copy ${worksrcpath}/maillib.crm ${destroot}${prefix}/share/doc/crm114/examples
99        file copy ${worksrcpath}/mailreaver.crm ${destroot}${prefix}/share/doc/crm114/examples
100        file copy ${worksrcpath}/mailtrainer.crm ${destroot}${prefix}/share/doc/crm114/examples
101        file copy ${worksrcpath}/match_isolate_reclaim.crm ${destroot}${prefix}/share/doc/crm114/examples
102        file copy ${worksrcpath}/match_isolate_test.crm ${destroot}${prefix}/share/doc/crm114/examples
103        file copy ${worksrcpath}/matchtest.crm ${destroot}${prefix}/share/doc/crm114/examples
104        file copy ${worksrcpath}/mathalgtest.crm ${destroot}${prefix}/share/doc/crm114/examples
105        file copy ${worksrcpath}/mathrpntest.crm ${destroot}${prefix}/share/doc/crm114/examples
106        file copy ${worksrcpath}/nestaliustest.crm ${destroot}${prefix}/share/doc/crm114/examples
107        file copy ${worksrcpath}/overalterisolatedtest.crm ${destroot}${prefix}/share/doc/crm114/examples
108        file copy ${worksrcpath}/pad.crm ${destroot}${prefix}/share/doc/crm114/examples
109        file copy ${worksrcpath}/paolo_ov2.crm ${destroot}${prefix}/share/doc/crm114/examples
110        file copy ${worksrcpath}/paolo_ov3.crm ${destroot}${prefix}/share/doc/crm114/examples
111        file copy ${worksrcpath}/paolo_ov4.crm ${destroot}${prefix}/share/doc/crm114/examples
112        file copy ${worksrcpath}/paolo_ov5.crm ${destroot}${prefix}/share/doc/crm114/examples
113        file copy ${worksrcpath}/paolo_overvars.crm ${destroot}${prefix}/share/doc/crm114/examples
114        file copy ${worksrcpath}/randomiotest.crm ${destroot}${prefix}/share/doc/crm114/examples
115        file copy ${worksrcpath}/rewritetest.crm ${destroot}${prefix}/share/doc/crm114/examples
116        file copy ${worksrcpath}/rewriteutil.crm ${destroot}${prefix}/share/doc/crm114/examples
117        file copy ${worksrcpath}/shroud.crm ${destroot}${prefix}/share/doc/crm114/examples
118        file copy ${worksrcpath}/shuffle.crm ${destroot}${prefix}/share/doc/crm114/examples
119        file copy ${worksrcpath}/skudtest.crm ${destroot}${prefix}/share/doc/crm114/examples
120        file copy ${worksrcpath}/statustest.crm ${destroot}${prefix}/share/doc/crm114/examples
121        file copy ${worksrcpath}/translate_tr.crm ${destroot}${prefix}/share/doc/crm114/examples
122        file copy ${worksrcpath}/traptest.crm ${destroot}${prefix}/share/doc/crm114/examples
123        file copy ${worksrcpath}/uncaughttraptest.crm ${destroot}${prefix}/share/doc/crm114/examples
124        file copy ${worksrcpath}/unionintersecttest.crm ${destroot}${prefix}/share/doc/crm114/examples
125        file copy ${worksrcpath}/userdirtest.crm ${destroot}${prefix}/share/doc/crm114/examples
126        file copy ${worksrcpath}/windowtest.crm ${destroot}${prefix}/share/doc/crm114/examples
127        file copy ${worksrcpath}/windowtest_fromvar.crm ${destroot}${prefix}/share/doc/crm114/examples
128       
129        # some of these seem to be dummy files
130        file copy ${worksrcpath}/blacklist.mfp ${destroot}${prefix}/share/doc/crm114/examples
131        file copy ${worksrcpath}/priolist.mfp ${destroot}${prefix}/share/doc/crm114/examples
132        file copy ${worksrcpath}/rewrites.mfp ${destroot}${prefix}/share/doc/crm114/examples
133        file copy ${worksrcpath}/test_rewrites.mfp ${destroot}${prefix}/share/doc/crm114/examples
134        file copy ${worksrcpath}/whitelist.mfp ${destroot}${prefix}/share/doc/crm114/examples
135       
136        # misc files (examples with using procmail etc...)
137        file copy ${worksrcpath}/procmailrc.recipe ${destroot}${prefix}/share/doc/crm114/examples
138        file copy ${worksrcpath}/reto_procmail_recipe.recipe ${destroot}${prefix}/share/doc/crm114/examples
139        file copy ${worksrcpath}/pad.dat ${destroot}${prefix}/share/doc/crm114/examples
140        file copy ${worksrcpath}/crm114-mode.el ${destroot}${prefix}/share/doc/crm114
141}
142