|
@@ -1,6 +1,17 @@
|
|
|
|
+%global system_zlib 1
|
|
|
|
+%global system_v8 1
|
|
|
|
+%global system_openssl 1
|
|
|
|
+%global system_http_parser 0
|
|
|
|
+%global system_cares 0
|
|
|
|
+%global system_libuv 0
|
|
|
|
+
|
|
|
|
+%if "%{_dist_release}" < "vl7"
|
|
|
|
+%global system_openssl 0
|
|
|
|
+%endif
|
|
|
|
+
|
|
Name: nodejs
|
|
Name: nodejs
|
|
Version: 0.10.0
|
|
Version: 0.10.0
|
|
-Release: 1%{?_dist_release}
|
|
+Release: 2%{?_dist_release}
|
|
Summary: JavaScript runtime
|
|
Summary: JavaScript runtime
|
|
Summary(ja): JavaScript runtime
|
|
Summary(ja): JavaScript runtime
|
|
License: MIT and ASL 2.0 and ISC and BSD
|
|
License: MIT and ASL 2.0 and ISC and BSD
|
|
@@ -23,16 +34,31 @@ Source6: nodejs-fixdep
|
|
%global v8_ge 3.13.7.5
|
|
%global v8_ge 3.13.7.5
|
|
%global v8_lt 3.14
|
|
%global v8_lt 3.14
|
|
|
|
|
|
|
|
+%if %{system_v8}
|
|
BuildRequires: v8-devel >= %{v8_ge}
|
|
BuildRequires: v8-devel >= %{v8_ge}
|
|
-#BuildRequires: http-parser-devel >= 2.0
|
|
+%endif
|
|
-#BuildRequires: libuv-devel
|
|
+%if %{system_http_parser}
|
|
-#BuildRequires: c-ares-devel
|
|
+BuildRequires: http-parser-devel >= 2.0
|
|
|
|
+%endif
|
|
|
|
+%if %{system_libuv}
|
|
|
|
+BuildRequires: libuv-devel
|
|
|
|
+%endif
|
|
|
|
+%if %{system_cares}
|
|
|
|
+BuildRequires: c-ares-devel
|
|
|
|
+%endif
|
|
|
|
+%if %{system_zlib}
|
|
BuildRequires: zlib-devel
|
|
BuildRequires: zlib-devel
|
|
|
|
+%endif
|
|
|
|
+
|
|
|
|
+%if %{system_openssl}
|
|
# Node.js requires some features from openssl 1.0.1 for SPDY support
|
|
# Node.js requires some features from openssl 1.0.1 for SPDY support
|
|
BuildRequires: openssl-devel >= 1.0.1
|
|
BuildRequires: openssl-devel >= 1.0.1
|
|
|
|
+%endif
|
|
|
|
|
|
|
|
+%if %{system_v8}
|
|
Requires: v8%{?isa}
|
|
Requires: v8%{?isa}
|
|
Requires: v8%{?isa} < %{v8_lt}
|
|
Requires: v8%{?isa} < %{v8_lt}
|
|
|
|
+%endif
|
|
|
|
|
|
#virtual provides for automatic depedency generation
|
|
#virtual provides for automatic depedency generation
|
|
Provides: nodejs(engine) = %{version}
|
|
Provides: nodejs(engine) = %{version}
|
|
@@ -57,8 +83,21 @@ Summary: JavaScript runtime - development headers
|
|
Summary(ja): JavaScript runtime - development headers
|
|
Summary(ja): JavaScript runtime - development headers
|
|
Group: Development/Languages
|
|
Group: Development/Languages
|
|
Requires: %{name} == %{version}-%{release}
|
|
Requires: %{name} == %{version}-%{release}
|
|
-#Requires: libuv-devel http-parser-devel openssl-devel c-ares-devel zlib-devel
|
|
+%if %{system_libuv}
|
|
-Requires: openssl-devel zlib-devel
|
|
+Requires: libuv-devel
|
|
|
|
+%endif
|
|
|
|
+%if %{system_http_parser}
|
|
|
|
+Requires: http-parser-devel
|
|
|
|
+%endif
|
|
|
|
+%if %{system_cares}
|
|
|
|
+Requires: c-ares-devel
|
|
|
|
+%endif
|
|
|
|
+%if %{system_zlib}
|
|
|
|
+Requires: zlib-devel
|
|
|
|
+%endif
|
|
|
|
+%if %{system_openssl}
|
|
|
|
+Requires: openssl-devel
|
|
|
|
+%endif
|
|
|
|
|
|
%description devel
|
|
%description devel
|
|
Development headers for the Node.js JavaScript runtime.
|
|
Development headers for the Node.js JavaScript runtime.
|
|
@@ -78,26 +117,35 @@ The API documentation for the Node.js JavaScript runtime.
|
|
# We only delete the source and header files, because
|
|
# We only delete the source and header files, because
|
|
# the remaining build scripts are still used.
|
|
# the remaining build scripts are still used.
|
|
|
|
|
|
-#find deps/cares -name "*.c" -exec rm -f {} \;
|
|
+%if %{system_cares}
|
|
-#find deps/cares -name "*.h" -exec rm -f {} \;
|
|
+find deps/cares -name "*.c" -exec rm -f {} \;
|
|
-
|
|
+find deps/cares -name "*.h" -exec rm -f {} \;
|
|
-#find deps/npm -name "*.c" -exec rm -f {} \;
|
|
+%endif
|
|
-#find deps/npm -name "*.h" -exec rm -f {} \;
|
|
|
|
|
|
|
|
|
|
+%if %{system_zlib}
|
|
find deps/zlib -name "*.c" -exec rm -f {} \;
|
|
find deps/zlib -name "*.c" -exec rm -f {} \;
|
|
find deps/zlib -name "*.h" -exec rm -f {} \;
|
|
find deps/zlib -name "*.h" -exec rm -f {} \;
|
|
|
|
+%endif
|
|
|
|
|
|
|
|
+%if %{system_v8}
|
|
find deps/v8 -name "*.c" -exec rm -f {} \;
|
|
find deps/v8 -name "*.c" -exec rm -f {} \;
|
|
find deps/v8 -name "*.h" -exec rm -f {} \;
|
|
find deps/v8 -name "*.h" -exec rm -f {} \;
|
|
|
|
+%endif
|
|
|
|
|
|
-#find deps/http_parser -name "*.c" -exec rm -f {} \;
|
|
+%if %{system_http_parser}
|
|
-#find deps/http_parser -name "*.h" -exec rm -f {} \;
|
|
+find deps/http_parser -name "*.c" -exec rm -f {} \;
|
|
|
|
+find deps/http_parser -name "*.h" -exec rm -f {} \;
|
|
|
|
+%endif
|
|
|
|
|
|
|
|
+%if %{system_openssl}
|
|
find deps/openssl -name "*.c" -exec rm -f {} \;
|
|
find deps/openssl -name "*.c" -exec rm -f {} \;
|
|
find deps/openssl -name "*.h" -exec rm -f {} \;
|
|
find deps/openssl -name "*.h" -exec rm -f {} \;
|
|
|
|
+%endif
|
|
|
|
|
|
-#find deps/uv -name "*.c" -exec rm -f {} \;
|
|
+%if %{system_libuv}
|
|
-#find deps/uv -name "*.h" -exec rm -f {} \;
|
|
+find deps/uv -name "*.c" -exec rm -f {} \;
|
|
|
|
+find deps/uv -name "*.h" -exec rm -f {} \;
|
|
|
|
+%endif
|
|
|
|
|
|
%build
|
|
%build
|
|
# build with debugging symbols and add defines from libuv (#892601)
|
|
# build with debugging symbols and add defines from libuv (#892601)
|
|
@@ -105,9 +153,24 @@ export CFLAGS='%{optflags} -g -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64'
|
|
export CXXFLAGS='%{optflags} -g -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64'
|
|
export CXXFLAGS='%{optflags} -g -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64'
|
|
|
|
|
|
./configure --prefix=%{_prefix} \
|
|
./configure --prefix=%{_prefix} \
|
|
- --shared-v8 \
|
|
+ %if %{system_v8}
|
|
- --shared-openssl \
|
|
+ --shared-v8 \
|
|
- --shared-zlib \
|
|
+ %endif
|
|
|
|
+ %if %{system_openssl}
|
|
|
|
+ --shared-openssl \
|
|
|
|
+ %endif
|
|
|
|
+ %if %{system_zlib}
|
|
|
|
+ --shared-zlib \
|
|
|
|
+ %endif
|
|
|
|
+ %if %{system_cares}
|
|
|
|
+ --shared-cares \
|
|
|
|
+ %endif
|
|
|
|
+ %if %{system_libuv}
|
|
|
|
+ --shared-libuv \
|
|
|
|
+ %endif
|
|
|
|
+ %if %{system_http_parser}
|
|
|
|
+ --shared-http-parser \
|
|
|
|
+ %endif
|
|
--without-dtrace
|
|
--without-dtrace
|
|
|
|
|
|
# Setting BUILDTYPE=Debug builds both release and debug binaries
|
|
# Setting BUILDTYPE=Debug builds both release and debug binaries
|
|
@@ -174,6 +237,9 @@ cp -p common.gypi %{buildroot}%{_datadir}/node
|
|
%doc LICENSE
|
|
%doc LICENSE
|
|
|
|
|
|
%changelog
|
|
%changelog
|
|
|
|
+* Fri Mar 15 2013 Daisuke SUZUKI <daisuke@linux.or.jp> 0.10.0-2
|
|
|
|
+- build with internal openssl on Vine Linux 6
|
|
|
|
+
|
|
* Wed Mar 13 2013 Daisuke SUZUKI <daisuke@linux.or.jp> 0.10.0-1
|
|
* Wed Mar 13 2013 Daisuke SUZUKI <daisuke@linux.or.jp> 0.10.0-1
|
|
- update to 0.10.0
|
|
- update to 0.10.0
|
|
|
|
|