From 0fa987f7d1dd0bc72f37c9aee941ee419ec8dea9 Mon Sep 17 00:00:00 2001 From: Matthias Saou Date: Feb 03 2008 12:42:05 +0000 Subject: Update to 1.7.0, as 1.70 to avoid introducing an epoch for now... --- diff --git a/.cvsignore b/.cvsignore index b6e62e9..fbf2e76 100644 --- a/.cvsignore +++ b/.cvsignore @@ -1 +1 @@ -js-1.60.tar.gz +js-1.7.0.tar.gz diff --git a/js-1.5-threadsafe.patch b/js-1.5-threadsafe.patch deleted file mode 100644 index b04a951..0000000 --- a/js-1.5-threadsafe.patch +++ /dev/null @@ -1,17 +0,0 @@ -diff -Naupr js.orig/src/Makefile.ref js/src/Makefile.ref ---- js.orig/src/Makefile.ref 2003-11-15 01:10:55.000000000 +0100 -+++ js/src/Makefile.ref 2006-07-24 17:06:59.000000000 +0200 -@@ -61,11 +61,11 @@ endif - - ifdef JS_THREADSAFE - DEFINES += -DJS_THREADSAFE --INCLUDES += -I../../dist/$(OBJDIR)/include -+INCLUDES += $(shell nspr-config --cflags) - ifdef USE_MSVC - OTHER_LIBS += ../../dist/$(OBJDIR)/lib/libnspr${NSPR_LIBSUFFIX}.lib - else --OTHER_LIBS += -L../../dist/$(OBJDIR)/lib -lnspr${NSPR_LIBSUFFIX} -+OTHER_LIBS += $(shell nspr-config --libs) - endif - endif - diff --git a/js-1.7.0-make.patch b/js-1.7.0-make.patch new file mode 100644 index 0000000..4622da2 --- /dev/null +++ b/js-1.7.0-make.patch @@ -0,0 +1,14 @@ +diff -Naupr js.orig/src/Makefile.ref js/src/Makefile.ref +--- js.orig/src/Makefile.ref 2006-07-26 21:16:47.000000000 +0200 ++++ js/src/Makefile.ref 2007-11-20 22:00:35.000000000 +0100 +@@ -335,8 +335,8 @@ ifdef USE_MSVC + $(PROGRAM): $(PROG_OBJS) $(LIBRARY) + link.exe -out:"$@" $(EXE_LINK_FLAGS) $^ + else +-$(PROGRAM): $(PROG_OBJS) $(LIBRARY) +- $(CC) -o $@ $(CFLAGS) $(PROG_OBJS) $(LIBRARY) $(LDFLAGS) $(OTHER_LIBS) \ ++$(PROGRAM): $(PROG_OBJS) $(SHARED_LIBRARY) ++ $(CC) -o $@ $(CFLAGS) $(PROG_OBJS) -L$(OBJDIR) -ljs $(LDFLAGS) $(OTHER_LIBS) \ + $(PROG_LIBS) + endif + diff --git a/js-1.7.0-threadsafe.patch b/js-1.7.0-threadsafe.patch new file mode 100644 index 0000000..55611c6 --- /dev/null +++ b/js-1.7.0-threadsafe.patch @@ -0,0 +1,17 @@ +diff -Naupr js.orig/src/Makefile.ref js/src/Makefile.ref +--- js.orig/src/Makefile.ref 2006-07-26 21:16:47.000000000 +0200 ++++ js/src/Makefile.ref 2007-11-20 22:03:59.000000000 +0100 +@@ -63,11 +63,11 @@ INCLUDES += -I$(OBJDIR) + + ifdef JS_THREADSAFE + DEFINES += -DJS_THREADSAFE +-INCLUDES += -I$(DIST)/include/nspr ++INCLUDES += $(shell nspr-config --cflags) + ifdef USE_MSVC + OTHER_LIBS += $(DIST)/lib/libnspr$(NSPR_LIBSUFFIX).lib + else +-OTHER_LIBS += -L$(DIST)/lib -lnspr$(NSPR_LIBSUFFIX) ++OTHER_LIBS += $(shell nspr-config --libs) + endif + endif + diff --git a/js-make.patch b/js-make.patch deleted file mode 100644 index 50c7710..0000000 --- a/js-make.patch +++ /dev/null @@ -1,13 +0,0 @@ ---- src/Makefile.ref.orig 2003-11-15 01:10:55.000000000 +0100 -+++ src/Makefile.ref 2004-03-02 03:55:53.000000000 +0100 -@@ -300,8 +300,8 @@ - $(PROGRAM): $(PROG_OBJS) $(LIBRARY) $(FDLIBM_LIBRARY) - link.exe -out:"$@" $(EXE_LINK_FLAGS) $^ - else --$(PROGRAM): $(PROG_OBJS) $(LIBRARY) $(FDLIBM_LIBRARY) -- $(CC) -o $@ $(CFLAGS) $(PROG_OBJS) $(LIBRARY) $(LDFLAGS) $(OTHER_LIBS) \ -+$(PROGRAM): $(PROG_OBJS) $(SHARED_LIBRARY) $(FDLIBM_LIBRARY) -+ $(CC) -o $@ $(CFLAGS) $(PROG_OBJS) -L$(OBJDIR) -ljs $(LDFLAGS) $(OTHER_LIBS) \ - $(PROG_LIBS) - endif - diff --git a/js.spec b/js.spec index bca7d42..7ce9380 100644 --- a/js.spec +++ b/js.spec @@ -1,9 +1,9 @@ -%{!?perl_vendorarch: %define perl_vendorarch %(eval "`%{__perl} -V:installvendorarch`"; echo $installvendorarch)} +%define real_version 1.7.0 Summary: JavaScript interpreter and libraries Name: js -Version: 1.60 -Release: 6%{?dist} +Version: 1.70 +Release: 1%{?dist} # The sources are triple licensed, but when we link against readline which is # GPL, the result can only be GPL. %if 0%{?_without_readline:1} @@ -13,19 +13,16 @@ License: GPLv2+ %endif Group: Development/Languages URL: http://www.mozilla.org/js/ -Source: http://ftp.mozilla.org/pub/mozilla.org/js/js-%{version}.tar.gz -Patch0: js-make.patch +Source: http://ftp.mozilla.org/pub/mozilla.org/js/js-%{real_version}.tar.gz +Patch0: js-1.7.0-make.patch Patch1: js-shlib.patch Patch2: js-1.5-va_copy.patch Patch3: js-ldflags.patch -Patch4: js-1.5-threadsafe.patch +Patch4: js-1.7.0-threadsafe.patch Patch5: js-1.60-ncurses.patch BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root -Requires: perl(:MODULE_COMPAT_%(eval "`%{__perl} -V:version`"; echo $version)) -BuildRequires: perl(ExtUtils::MakeMaker), perl(ExtUtils::Embed) -Buildrequires: readline-devel, ncurses-devel, nspr-devel -# Temporary fix (#226970 - nspr-devel should require pkgconfig) -Buildrequires: pkgconfig +Buildrequires: nspr-devel +Buildrequires: readline-devel, ncurses-devel Provides: libjs = %{version}-%{release} %description @@ -37,7 +34,8 @@ for embedding in applications. %package devel Summary: Header files, libraries and development documentation for %{name} Group: Development/Libraries -Requires: %{name} = %{version}-%{release}, pkgconfig +Requires: %{name} = %{version}-%{release} +Requires: pkgconfig Provides: libjs-devel = %{version}-%{release} %description devel @@ -48,13 +46,12 @@ you will need to install %{name}-devel. %prep %setup -q -n %{name} -%patch0 -p0 -b .make +%patch0 -p1 -b .make %patch1 -p0 -b .shlib %patch2 -p1 -b .vacopy %patch3 -p0 -b .ldflags %patch4 -p1 -b .threadsafe %patch5 -p1 -b .ncurses -%{__cp} src/perlconnect/README.html src/README.perlconnect.html # Create pkgconfig file %{__cat} > libjs.pc << 'EOF' @@ -66,7 +63,7 @@ includedir=%{_includedir} Name: libjs Description: JS library Requires: -Version: %{version} +Version: %{real_version} Libs: -L${libdir} -ljs Cflags: -I${includedir} EOF @@ -74,19 +71,13 @@ EOF %build export BUILD_OPT=1 -%{__make} -C src -f Makefile.ref \ +%{__make} %{?_smp_mflags} -C src -f Makefile.ref \ JS_THREADSAFE="1" \ XCFLAGS="%{optflags} -fPIC" \ BUILD_OPT="1" \ %if 0%{!?_without_readline:1} - JS_READLINE="1" \ + JS_READLINE="1" %endif - JS_PERLCONNECT="1" - -cd src/perlconnect - MAKEFLAGS=-s %{__perl} Makefile.PL INSTALLDIRS=vendor - %{__make} %{?_smp_mflags} OPTIMIZE="%{optflags}" -cd - %install @@ -107,23 +98,12 @@ cd - %{buildroot}%{_includedir}/ %{__install} -m 0644 libjs.pc \ %{buildroot}%{_libdir}/pkgconfig/ -%{__make} -C src/perlconnect pure_install PERL_INSTALL_ROOT=%{buildroot} -# Remove unwanted perl related files -find %{buildroot} -type f -name .packlist -o -name jsperlbuild.pl | xargs -r rm -find %{buildroot} -type f -name '*.bs' -a -size 0 | xargs -r rm -# For some reason, the pure_install above doesn't set u+w :-( -find %{buildroot}%{perl_vendorarch} -type f -exec %{__chmod} u+w {} \; %clean %{__rm} -rf %{buildroot} -%check || : -ln -s libjs.so src/Linux_All_OPT.OBJ/libjs.so.1 -LD_LIBRARY_PATH=`pwd`/src/Linux_All_OPT.OBJ %{__make} -C src/perlconnect test - - %post -p /sbin/ldconfig %postun -p /sbin/ldconfig @@ -131,11 +111,9 @@ LD_LIBRARY_PATH=`pwd`/src/Linux_All_OPT.OBJ %{__make} -C src/perlconnect test %files %defattr(-,root,root,-) -%doc src/README*.html src/perlconnect/bg.jpg +%doc src/README.html %{_bindir}/js %{_libdir}/*.so.* -%{perl_vendorarch}/auto/JS/ -%{perl_vendorarch}/*.pm %files devel %defattr(-,root,root,-) @@ -149,6 +127,10 @@ LD_LIBRARY_PATH=`pwd`/src/Linux_All_OPT.OBJ %{__make} -C src/perlconnect test %changelog +* Sun Feb 3 2008 Matthias Saou 1.70-1 +- Update to 1.7.0, as 1.70 to avoid introducing an epoch for now... +- Remove no longer provided perlconnect parts. + * Thu Jan 24 2008 Tom "spot" Callaway 1.60-6 - BR: perl(ExtUtils::Embed) diff --git a/sources b/sources index 5450ce8..8658152 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -bd8f021e43a8fbbec55ac2cd3d483243 js-1.60.tar.gz +5571134c3863686b623ebe4e6b1f6fe6 js-1.7.0.tar.gz