afcda54f90c0723baea2d2ec9fd833f4d919c3f5
[scm/bb/meta-tizen.git] / recipes-tizen / xdgmime / xdgmime.inc
1 DESCRIPTION = "Pkg xdgmime"
2 HOMEPAGE = "http://nohomepage.org"
3 SECTION = "TO_BE/FILLED_IN"
4 LICENSE = "LGPLv2, AFLv2"
5
6 SRC_URI = ""
7
8 S = "${WORKDIR}/git"
9
10 inherit autotools-brokensep
11
12 PROVIDES = ""
13
14 #PROVIDES by xdgmime-dev 
15
16
17 #PROVIDES by xdgmime 
18
19
20 RDEPENDS = ""
21 #RDEPENDS of xdgmime-dev (${PN}-dev)
22 RDEPENDS_${PN}-dev += "xdgmime"
23
24
25 DEPENDS = ""
26 #DEPENDS of xdgmime 
27 DEPENDS_append_class-native = " cmake-native"
28 DEPENDS_append_class-target = " cmake-native"
29
30 do_prep() {
31  cd ${S}
32  chmod -Rf a+rX,u+w,g-w,o-w ${S}
33  #setup -q
34  cp ${S}/packaging/xdgmime.manifest .
35  
36  
37 }
38 do_patch_append() {
39     bb.build.exec_func('do_prep', d)
40 }
41
42 do_configure() {
43 }
44
45 do_compile() {
46  cd ${S}
47  LANG=C
48  export LANG
49  unset DISPLAY
50  CFLAGS="-O2 -g -m64 -fmessage-length=0 -D_FORTIFY_SOURCE=2 -fstack-protector -funwind-tables -fasynchronous-unwind-tables" ; export CFLAGS ; 
51  CXXFLAGS="${CXXFLAGS:--O2 -g -m64 -fmessage-length=0 -D_FORTIFY_SOURCE=2 -fstack-protector -funwind-tables -fasynchronous-unwind-tables}" ; export CXXFLAGS ; 
52  FFLAGS="${FFLAGS:--O2 -g -m64 -fmessage-length=0 -D_FORTIFY_SOURCE=2 -fstack-protector -funwind-tables -fasynchronous-unwind-tables -I%_fmoddir}" ; export FFLAGS ; 
53  LD_AS_NEEDED=1; export LD_AS_NEEDED ; 
54  
55  
56    CFLAGS="${CFLAGS:--O2 -g -m64 -fmessage-length=0 -D_FORTIFY_SOURCE=2 -fstack-protector -funwind-tables -fasynchronous-unwind-tables}" ; export CFLAGS ; 
57    CXXFLAGS="${CXXFLAGS:--O2 -g -m64 -fmessage-length=0 -D_FORTIFY_SOURCE=2 -fstack-protector -funwind-tables -fasynchronous-unwind-tables}" ; export CXXFLAGS ; 
58    FFLAGS="${FFLAGS:--O2 -g -m64 -fmessage-length=0 -D_FORTIFY_SOURCE=2 -fstack-protector -funwind-tables -fasynchronous-unwind-tables}" ; export FFLAGS ; 
59    cmake \
60          -DCMAKE_VERBOSE_MAKEFILE=ON \
61          -DCMAKE_INSTALL_PREFIX:PATH=${prefix} \
62          -DCMAKE_INSTALL_LIBDIR:PATH=${prefix}/lib \
63          -DINCLUDE_INSTALL_DIR:PATH=${prefix}/include \
64          -DLIB_INSTALL_DIR:PATH=${prefix}/lib \
65          -DSYSCONF_INSTALL_DIR:PATH=${sysconfdir} \
66          -DSHARE_INSTALL_PREFIX:PATH=${prefix}/share \
67          -DCMAKE_SKIP_RPATH:BOOL=ON \
68          -DBUILD_SHARED_LIBS:BOOL=ON . 
69  
70  make -j16
71  
72  
73  
74 }
75
76 do_install() {
77  echo export RPM_BUILD_ROOT=${D}
78  cd ${S}
79  LANG=C
80  export LANG
81  unset DISPLAY
82  rm -rf ${D} 
83  mkdir -p ${D} 
84  
85  
86    oe_runmake \
87          DESTDIR=${D} \
88          INSTALL_ROOT=${D} \
89          BINDIR=${prefix}/bin \
90    install  
91    rm -f ${D}${infodir}/dir 
92    find ${D} -regex ".*\.la$" | xargs rm -f -- 
93    find ${D} -regex ".*\.a$" | xargs rm -f --
94  
95  
96 }
97
98
99 xdgmime-dev_files = ""
100 xdgmime-dev_files += "xdgmime.manifest"
101 xdgmime-dev_files += "${prefix}/include/xdgmime.h"
102 xdgmime-dev_files += "${prefix}/lib/libxdgmime.so"
103 xdgmime-dev_files += "${prefix}/lib/pkgconfig/xdgmime.pc"
104
105 xdgmime_files = ""
106 xdgmime_files += "xdgmime.manifest"
107 xdgmime_files += "${prefix}/lib/libxdgmime.so.*"
108 xdgmime_files += "xdgmime.manifest"
109
110 FILES_${PN}-dev = "${xdgmime-dev_files}"
111 FILES_${PN} = "${xdgmime_files}"
112
113 PKG_xdgmime-dev= "xdgmime-dev"
114 PKG_xdgmime= "xdgmime"
115
116 require xdgmime-extraconf.inc
117