]> git.pld-linux.org Git - packages/ucblogo.git/commitdiff
- updated to 6.0
authorJakub Bogusz <qboosh@pld-linux.org>
Thu, 16 May 2013 19:28:10 +0000 (21:28 +0200)
committerJakub Bogusz <qboosh@pld-linux.org>
Thu, 16 May 2013 19:28:10 +0000 (21:28 +0200)
- updated make patch
- added wx patch (fixes build with unicode wxWidgets)

ucblogo-make.patch
ucblogo-wx.patch [new file with mode: 0644]
ucblogo.spec

index 49b3caeca6a88102c6671c2bae2ad7e90e48586c..3d8ff86475be33c7768e55358768f5cb17165f22 100644 (file)
@@ -1,56 +1,56 @@
---- ucblogo-5.2/emacs/makefile.orig    Tue Dec 10 13:51:05 2002
-+++ ucblogo-5.2/emacs/makefile Tue Dec 10 13:50:48 2002
-@@ -1,5 +1,5 @@
- BUILDIR             = `pwd`
--INFODIR             = $(prefix)/info
-+INFODIR             = $(prefix)/share/info
- EMACSDIR      = $(LIBLOC)/emacs
- DOCSDIR             = $(LIBLOC)/docs
- HTMLDIR             = $(DOCSDIR)/html
---- ucblogo-5.2/makefile.in.orig       Tue Dec 10 13:46:05 2002
-+++ ucblogo-5.2/makefile.in    Tue Dec 10 14:09:43 2002
-@@ -4,7 +4,7 @@
+--- ucblogo-6.0/makefile.in.orig       2013-05-15 19:59:50.770414901 +0200
++++ ucblogo-6.0/makefile.in    2013-05-16 17:07:42.770555795 +0200
+@@ -6,7 +6,7 @@
  LIBS  = @X_PRE_LIBS@ @X_LIBS@ @LIBS@ @X_EXTRA_LIBS@
  prefix = @prefix@
  BINDIR        = $(prefix)/bin
 -LIBLOC        = $(prefix)/lib/logo
 +LIBLOC        = $(prefix)/share/logo
+ LINKER = @LINKER@
  
  # LIBLOC      = `pwd`
+@@ -71,11 +71,11 @@
+       cd docs; $(MAKE) ship
  
-@@ -54,25 +54,25 @@
- clean:
-       rm -f *.o libloc.c
--      cd emacs; gmake clean
-+      cd emacs; $(MAKE) clean
- ship:
-       rm -f config.h config.cache config.log config.status
-       rm -f makefile makehelp logo *.o libloc.c
--      cd emacs; gmake ship
-+      cd emacs; $(MAKE) ship
- install: all
+-install: all
 -      for d in $(BINDIR) $(LIBLOC) $(LIBLOC)/logolib $(LIBLOC)/helpfiles $(LIBLOC)/csls; do [ -d $$d ] || mkdir -p $$d || exit 1; done
 -      cp logo $(BINDIR)/.
 -      cp -f logolib/* $(LIBLOC)/logolib/.
 -      cp -f helpfiles/* $(LIBLOC)/helpfiles/.
 -      cp -f csls/* $(LIBLOC)/csls/.
--      (cd emacs; prefix=$(prefix) LIBLOC=$(LIBLOC) BINDIR=$(BINDIR) gmake install)
++install: logo
 +      for d in $(DESTDIR)$(BINDIR) $(DESTDIR)$(LIBLOC) $(DESTDIR)$(LIBLOC)/logolib $(DESTDIR)$(LIBLOC)/helpfiles $(DESTDIR)$(LIBLOC)/csls; do [ -d $$d ] || mkdir -p $$d || exit 1; done
 +      cp logo $(DESTDIR)$(BINDIR)/.
 +      cp -f logolib/* $(DESTDIR)$(LIBLOC)/logolib/.
 +      cp -f helpfiles/* $(DESTDIR)$(LIBLOC)/helpfiles/.
 +      cp -f csls/* $(DESTDIR)$(LIBLOC)/csls/.
-+      (cd emacs; prefix=$(DESTDIR)$(prefix) LIBLOC=$(DESTDIR)$(LIBLOC) BINDIR=$(DESTDIR)$(BINDIR) $(MAKE) install)
- #     prefix=$(prefix); LIBLOC=$(LIBLOC); BINDIR=$(BINDIR); export prefix LIBLOC BINDIR; cd emacs; gmake install
+ #     (cd emacs; prefix=$(prefix) LIBLOC=$(LIBLOC) BINDIR=$(BINDIR) $(MAKE) install)
+       (cd docs; prefix=$(prefix) LIBLOC=$(LIBLOC) BINDIR=$(BINDIR) $(MAKE) install)
+ #     prefix=$(prefix); LIBLOC=$(LIBLOC); BINDIR=$(BINDIR); export prefix LIBLOC BINDIR; cd emacs; $(MAKE) install
+--- ucblogo-6.0/docs/makefile.orig     2008-08-19 21:56:59.000000000 +0200
++++ ucblogo-6.0/docs/makefile  2013-05-16 17:08:36.163886889 +0200
+@@ -1,5 +1,5 @@
+ BUILDIR             = `pwd`
+-INFODIR             = $(prefix)/info
++INFODIR             = $(prefix)/share/info
+ DOCSDIR             = $(LIBLOC)/docs
+ HTMLDIR             = $(DOCSDIR)/html
  
- logo-mode: 
--      (cd emacs; prefix=$(prefix) LIBLOC=$(LIBLOC) BINDIR=$(BINDIR) gmake)
-+      (cd emacs; prefix=$(prefix) LIBLOC=$(LIBLOC) BINDIR=$(BINDIR) $(MAKE))
- #     @prefix=$(prefix); LIBLOC=$(LIBLOC); BINDIR=$(BINDIR); export prefix LIBLOC BINDIR; cd emacs; gmake
+@@ -31,10 +31,10 @@
+       -rm -f *.{aux,cp,cps,dvi,fn,ky,log,pg,toc,tp,vr}
  
- docs:
--      cd emacs; gmake docs
-+      cd emacs; $(MAKE) docs
+ install: all
+-      for d in $(INFODIR) $(DOCSDIR) $(HTMLDIR); do [ -d $$d ] || mkdir -p $$d || exit 1; done
+-      -cp -f *.info* $(INFODIR)/.
+-      -cp -f html/*.html $(HTMLDIR)/.
+-      -cp -f usermanual.ps $(DOCSDIR)/.
+-      -cp -f usermanual.pdf $(DOCSDIR)/.
+-      -cp -f usermanual.texi $(DOCSDIR)/.
+-      -cp -f ../usermanual $(DOCSDIR)/.
++      for d in $(INFODIR) $(DOCSDIR) $(HTMLDIR); do [ -d $(DESTDIR)$$d ] || mkdir -p $(DESTDIR)$$d || exit 1; done
++      -cp -f *.info* $(DESTDIR)$(INFODIR)/.
++      -cp -f html/*.html $(DESTDIR)$(HTMLDIR)/.
++      -cp -f usermanual.ps $(DESTDIR)$(DOCSDIR)/.
++      -cp -f usermanual.pdf $(DESTDIR)$(DOCSDIR)/.
++      -cp -f usermanual.texi $(DESTDIR)$(DOCSDIR)/.
++      -cp -f ../usermanual $(DESTDIR)$(DOCSDIR)/.
diff --git a/ucblogo-wx.patch b/ucblogo-wx.patch
new file mode 100644 (file)
index 0000000..84cef3a
--- /dev/null
@@ -0,0 +1,49 @@
+--- ucblogo-6.0/wxTerminal.cpp.orig    2008-09-14 06:57:09.000000000 +0200
++++ ucblogo-6.0/wxTerminal.cpp 2013-05-16 20:28:02.600051372 +0200
+@@ -938,7 +938,7 @@ wxTerminal::GetCharSize(int *cw, int *ch
+   //dc.GetTextExtent("(", &dummy, ch);
+   int descent, extlead; 
+-  dc.GetTextExtent("M", cw, ch, &descent, &extlead);
++  dc.GetTextExtent(wxT("M"), cw, ch, &descent, &extlead);
+   //for the tails of g's and y's, if needed.
+ #ifdef __WXMSW__
+     *ch += descent + extlead + 1;
+--- ucblogo-6.0/wxTurtleGraphics.cpp.orig      2008-09-14 01:23:42.000000000 +0200
++++ ucblogo-6.0/wxTurtleGraphics.cpp   2013-05-16 20:28:53.780049221 +0200
+@@ -558,7 +558,7 @@ extern "C" FLONUM y_scale;
+ extern "C" void wx_get_label_size(int *w, int *h) {
+     /* returns size in pixels; converted to turtle steps in wxterm.c */
+   int descent, extlead;
+-  m_memDC->GetTextExtent("M", w, h, &descent, &extlead);  
++  m_memDC->GetTextExtent(wxT("M"), w, h, &descent, &extlead);  
+ }
+ extern "C" void wx_adjust_label_height() {
+@@ -573,7 +573,7 @@ extern "C" void wx_adjust_label_height()
+     label_font.SetPointSize(font_size);
+     m_memDC->SetFont(label_font);     
+-    m_memDC->GetTextExtent("M", &cw, &ch, &descent, &extlead);
++    m_memDC->GetTextExtent(wxT("M"), &cw, &ch, &descent, &extlead);
+     //now... first figure out whether we undershot or overshot...
+     //this determines which direction to change the size
+@@ -592,7 +592,7 @@ extern "C" void wx_adjust_label_height()
+           }
+           if (expected == 100) break;
+           m_memDC->SetFont(tmp_font); 
+-          m_memDC->GetTextExtent("M", &cw, &tmp_height, &descent, &extlead);
++          m_memDC->GetTextExtent(wxT("M"), &cw, &tmp_height, &descent, &extlead);
+           if(tmp_height >= px_height) break;
+@@ -611,7 +611,7 @@ extern "C" void wx_adjust_label_height()
+           }
+           if (expected == 2) break;
+           m_memDC->SetFont(tmp_font); 
+-          m_memDC->GetTextExtent("M", &cw, &tmp_height, &descent, &extlead);
++          m_memDC->GetTextExtent(wxT("M"), &cw, &tmp_height, &descent, &extlead);
+           if(tmp_height <= px_height) break;
index d3d39406270eea8e3e484b6e1154c5440bb143f4..a6d5789ffe38b0967f163daafca329737cd96e05 100644 (file)
@@ -1,18 +1,19 @@
 Summary:       Berkeley LOGO interpreter
 Summary(pl.UTF-8):     Interpreter Berkeley LOGO
 Name:          ucblogo
-Version:       5.3
+Version:       6.0
 Release:       1
-License:       GPL
+License:       GPL v2+
 Group:         Development/Languages
 Source0:       ftp://anarres.cs.berkeley.edu/pub/ucblogo/%{name}-%{version}.tar.gz
-# Source0-md5: d10fb7ef5d36c38d54cfe5f2f3f7b5d6
+# Source0-md5: 36a56765b18136c817880c5381af196b
 Patch0:                %{name}-signals.patch
 Patch1:                %{name}-make.patch
-BuildRequires: XFree86-devel
-BuildRequires: autoconf
-BuildRequires: emacs
+Patch2:                %{name}-wx.patch
+URL:           http://www.cs.berkeley.edu/~bh/logo.html
 BuildRequires: ncurses-devel
+BuildRequires: wxGTK2-unicode-devel
+BuildRequires: xorg-lib-libX11-devel
 BuildRoot:     %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
 
 %description
@@ -43,11 +44,22 @@ plot i wiele innych.
 %setup -q
 %patch0 -p1
 %patch1 -p1
+%patch2 -p1
+
+%{__rm} -r csls/CVS
 
 %build
-%{__autoconf}
-%configure --with-x
-%{__make} "CFLAGS=%{rpmcflags}"
+# configure is manually hacked for wx support
+export ac_cv_lib_termcap_tgetstr=no
+export ac_cv_lib_termlib_tgetstr=no
+%configure2_13 \
+       --with-x \
+       --wx-config_path=%{_bindir}/wx-gtk2-unicode-config \
+       --wx-enable
+%{__make} \
+       CC="%{__cc}" \
+       CXX="%{__cxx}" \
+       CFLAGS="%{rpmcflags}"
 
 %install
 rm -rf $RPM_BUILD_ROOT
@@ -55,27 +67,27 @@ rm -rf $RPM_BUILD_ROOT
 %{__make} install \
        DESTDIR=$RPM_BUILD_ROOT
 
-install -d $RPM_BUILD_ROOT%{_examplesdir}/logo
-install csls/* $RPM_BUILD_ROOT%{_examplesdir}/logo
+install -d $RPM_BUILD_ROOT%{_examplesdir}/%{name}-%{version}
+install csls/* $RPM_BUILD_ROOT%{_examplesdir}/%{name}-%{version}
+
+%{__rm} $RPM_BUILD_ROOT%{_datadir}/logo/docs/usermanual.{ps,texi}
 
 %clean
 rm -rf $RPM_BUILD_ROOT
 
-%post  -p      /sbin/postshell
+%post  -p /sbin/postshell
 -/usr/sbin/fix-info-dir -c %{_infodir}
 
-%postun        -p      /sbin/postshell
+%postun        -p /sbin/postshell
 -/usr/sbin/fix-info-dir -c %{_infodir}
 
 %files
 %defattr(644,root,root,755)
-%attr(755,root,root) %{_bindir}/*
-%{_infodir}/*.info*
-%dir %{_datadir}/logo
-%{_datadir}/logo/*
-%doc README
+%doc README TODO changes.txt newtermnotes plm usermanual
+%attr(755,root,root) %{_bindir}/logo
+%{_infodir}/ucblogo.info*
+%{_datadir}/logo
 
 %files examples
 %defattr(644,root,root,755)
-%dir %{_examplesdir}/logo
-%{_examplesdir}/logo/*
+%{_examplesdir}/%{name}-%{version}
This page took 0.140735 seconds and 4 git commands to generate.