Package libmozjs60: Specfile
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 | %define ver_major 60 %def_enable optimize %def_without system_icu %def_without system_nspr %if_without system_nspr %def_enable posix_nspr_emulation %endif ## fc # Big endian platforms %ifarch ppc ppc64 s390 s390x %def_enable big_endian %endif %if "%(rpmvercmp '%{get_version libicu-devel}' '5.9.1')" < "0" %def_disable system_icu %endif Name: libmozjs%ver_major Version: %ver_major.8.0 Release: alt2 Summary: JavaScript interpreter and libraries Group: System/Libraries License: MPL-2.0 and GPL-2.0-or-later LGPL-2.1-or-later and BSD Url: https://developer.mozilla.org/en-US/docs/Mozilla/Projects/SpiderMonkey/Releases/ #Source: %name-%version.tar Source: https://ftp.gnome.org/pub/gnome/teams/releng/tarballs-needing-help/mozjs/mozjs-%version.tar.bz2 #Source: https://ftp.mozilla.org/pub/firefox/releases/%{version}esr/source/firefox-%{version}esr.source.tar.xz BuildRequires: /dev/shm BuildRequires: gcc-c++ libreadline-devel zip unzip BuildRequires: libffi-devel libffi-devel-static BuildRequires: python-module-distribute BuildRequires: python-module-json BuildRequires: zlib-devel %{?_with_system_icu:BuildRequires: libicu-devel} %{?_with_system_nspr:BuildRequires: libnspr-devel} BuildRequires: autoconf_2.13 %set_autoconf_version 2.13 %description JavaScript is the Netscape-developed object scripting language used in millions of web pages and server applications worldwide. Netscape's JavaScript is a super set of the ECMA-262 Edition 3 (ECMAScript) standard scripting language, with only mild differences from the published standard. %package devel Summary: Header files, libraries and development documentation for %name Group: Development/C++ Requires: %name = %version-%release %description devel This package contains the header files, static libraries and development documentation for %name. If you like to develop programs using %name, you will need to install %name-devel. %package devel-static Summary: SpiderMonkey static libraries Group: Development/C++ Requires: %name-devel = %version-%release %description devel-static SpiderMonkey development kit (static libs) %package tools Summary: Tools for the SpiderMonkey Group: Development/Other %description tools SpiderMonkey is the code-name for the Mozilla's C implementation of JavaScript. This package provides standalone SpiderMonkey shell, a command line interface to the JavaScript engine. %prep #%%setup -n firefox-%{version}esr %setup -n mozjs-%version %build export srcdir="$PWD" mkdir _build cd _build %add_optflags %optflags_shared %(getconf LFS_CFLAGS) export CFLAGS="%optflags" export CXXFLAGS="$CFLAGS -fno-tree-vrp -fno-strict-aliasing -fno-delete-null-pointer-checks" export SHELL=/bin/sh export PYTHON=/usr/bin/python2 ../js/src/configure \ --prefix=%_prefix \ --libdir=%_libdir \ --disable-strip \ --enable-pie \ --disable-jemalloc \ --enable-readline \ --enable-shared-js \ %{?_with_system_nspr:--with-system-nspr} \ %{?_enable_posix_nspr_emulation:--enable-posix-nspr-emulation} \ %{subst_enable optimize} \ --with-system-zlib \ %{?_with_system_icu:--with-system-icu} \ --with-intl-api \ %ifarch %{arm} aarch64 ppc ppc64 --disable-ion %endif %if_enabled big_endian echo "Generate big endian version of config/external/icu/data/icud58l.dat" pushd ../.. ./mach python intl/icu_sources_data.py . ls -l config/external/icu/data rm -f config/external/icu/data/icudt*l.dat popd %endif %make_build %install cd _build %makeinstall_std chmod a-x %buildroot/%_pkgconfigdir/*.pc [ ! -f %buildroot/%_pkgconfigdir/js.pc ] || mv -f -- \ %buildroot/%_pkgconfigdir/js.pc \ %buildroot/%_pkgconfigdir/mozjs-%ver_major.pc (set -x for f in %buildroot/%_libdir/*.ajs; do mv -vf -- "$f" "${f%%js}" done ) # Install files, not symlinks to build directory (set +x find -P "%buildroot/%_includedir" -type l -printf '%%p\n' | while read link; do t="$(readlink -ev "$link")" rm -f -- "$link" cp -f -- "$t" "$link" done ) cp -p js/src/js-config.h %buildroot/%_includedir/mozjs-%ver_major %files %_libdir/libmozjs-%ver_major.so* %files devel %_pkgconfigdir/mozjs-%ver_major.pc %_includedir/mozjs-%ver_major/ %files tools %_bindir/js%ver_major %_bindir/js%ver_major-config %files devel-static %_libdir/*.a %changelog * Fri May 01 2020 Yuri N. Sedunov <aris@altlinux.org> 60.8.0-alt2 - fixed build with python2 - fixed License tag * Wed Aug 28 2019 Yuri N. Sedunov <aris@altlinux.org> 60.8.0-alt1 - 60.8.0 * Mon Jul 30 2018 Yuri N. Sedunov <aris@altlinux.org> 60.1.0-alt1 - first build for Sisyphus |