Hello community,

here is the log from the commit of package gcc for openSUSE:Factory checked in 
at 2018-06-26 10:29:26
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/gcc (Old)
 and      /work/SRC/openSUSE:Factory/.gcc.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "gcc"

Tue Jun 26 10:29:26 2018 rev:62 rq:617715 version:8

Changes:
--------
--- /work/SRC/openSUSE:Factory/gcc/gcc.changes  2018-06-08 23:08:49.886437088 
+0200
+++ /work/SRC/openSUSE:Factory/.gcc.new/gcc.changes     2018-06-26 
10:29:30.140256250 +0200
@@ -1,0 +2,6 @@
+Wed Jun 13 07:13:07 UTC 2018 - [email protected]
+
+- Add gccgo symlink, add go and gofmt as alternatives to support
+  parallel install of golang.  [bnc#1096677]
+
+-------------------------------------------------------------------
@@ -4,0 +11 @@
+  [bnc#1096008]

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ gcc.spec ++++++
--- /var/tmp/diff_new_pack.nFTDeT/_old  2018-06-26 10:29:32.952152973 +0200
+++ /var/tmp/diff_new_pack.nFTDeT/_new  2018-06-26 10:29:32.968152385 +0200
@@ -345,6 +345,8 @@
 Group:          Development/Languages/C and C++
 Requires:       gcc = %{version}
 Requires:       gcc%{gcc_version}-go
+Requires(post): update-alternatives
+Requires(postun): update-alternatives
 
 %description -n gcc-go
 The system GNU Go Compiler.
@@ -385,6 +387,7 @@
         g++ \
         cpp \
         gfortran \
+       gccgo \
 %if %{build_ada}
        gnat gnatbind gnatbl gnatchop gnatclean gnatfind gnatkr \
        gnatlink gnatls gnatmake gnatname gnatprep gnatxref gprmake \
@@ -393,12 +396,17 @@
     ; do
   ln -sf $program-%{gcc_suffix} $RPM_BUILD_ROOT%{_prefix}/bin/$program
 done
+# For go and gofmt use alternatives since they are shared with golang
+mkdir -p %{buildroot}%{_sysconfdir}/alternatives
+ln -sf %{_sysconfdir}/alternatives/go %{buildroot}%{_bindir}/go
+ln -sf %{_sysconfdir}/alternatives/gofmt %{buildroot}%{_bindir}/gofmt
 # Link section 1 manpages
 for man1 in \
         gcc gcov gcov-dump gcov-tool \
         g++ \
         cpp \
         gfortran \
+       gccgo \
     ; do
   ln -sf $man1-%{gcc_suffix}.1.gz $RPM_BUILD_ROOT%{_mandir}/man1/$man1.1.gz
 done
@@ -426,6 +434,20 @@
 
%%{pie|fpic|fPIC|fpie|fPIE|no-pie|fno-pic|fno-PIC|fno-pie|fno-PIE|shared|static|nostdlib|nodefaultlibs|nostartfiles:;:-fPIE
 -pie}
 EOF
 
+%post -n gcc-go
+# we don't want a BuildRequires on gccN-go but otherwise the install
+# step of the build fails, so simply skip the script when gccN-go isn't there
+if [ -f %{_bindir}/go-%{gcc_suffix} ] ; then
+update-alternatives \
+  --install %{_bindir}/go go %{_bindir}/go-%{gcc_suffix} 100 \
+  --slave %{_bindir}/gofmt gofmt %{_bindir}/gofmt-%{gcc_suffix}
+fi
+
+%postun -n gcc-go
+if [ $1 -eq 0 ] ; then
+  update-alternatives --remove go %{_bindir}/go-%{gcc_suffix}
+fi
+
 %files
 %defattr(-,root,root)
 %{_prefix}/bin/gcc
@@ -516,7 +538,12 @@
 
 %files -n gcc-go
 %defattr(-,root,root)
-# empty - only for the dependency
+%{_bindir}/gccgo
+%{_bindir}/go
+%{_bindir}/gofmt
+%ghost %{_sysconfdir}/alternatives/go
+%ghost %{_sysconfdir}/alternatives/gofmt
+%doc %{_mandir}/man1/gccgo.1.gz
 
 %if %{separate_bi32}
 


Reply via email to