This service will be undergoing maintenance at 00:00 UTC, 2016-09-28. It is expected to last about 1 hours
Bug 148936 - Patch to spec file to conditionally deactivate X11 support
Patch to spec file to conditionally deactivate X11 support
Status: CLOSED RAWHIDE
Product: Fedora
Classification: Fedora
Component: VFlib2 (Show other bugs)
3
All Linux
medium Severity medium
: ---
: ---
Assigned To: Akira TAGOH
Bill Huang
: FutureFeature
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2005-02-16 20:31 EST by Philip Gwyn
Modified: 2007-11-30 17:11 EST (History)
0 users

See Also:
Fixed In Version: 2.25.6-27
Doc Type: Enhancement
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2005-02-23 01:57:22 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:


Attachments (Terms of Use)

  None (edit)
Description Philip Gwyn 2005-02-16 20:31:17 EST
From Bugzilla Helper:
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.7.3)
Gecko/20040914

Description of problem:
This patch adds %define use_X to the spec file.  This define is then
used to conditionnaly turn functionnaly that needs X11 on or off.

Deactivating X11 is useful for servers.

VFlib2 without X11 will not have disol, fmtest, kban, vfperf, vftest.

Version-Release number of selected component (if applicable):
2.25.6-25

How reproducible:
Always

Steps to Reproduce:
1. Do a default install of FC3
2. rpm -e xorg-x11-libs
Step 2 fails, because, amoungst others, VFlib2 requires the X11 libraries

Additional info:

--- SPECS/VFlib2.spec   2004-10-04 06:22:17.000000000 -0400
+++ SPECS.noX/VFlib2.spec   2005-02-16 19:29:51.162990239 -0500
@@ -1,10 +1,20 @@
+# set to 0 to disable X11 bits
+%define use_X 0
+
 Name:      VFlib2
 Version:   2.25.6
+%if %{use_X} 
 Release:   25
+%else
+Release:   25.noX
+%endif
 License:   GPL
 URL:       http://TypeHack.aial.hiroshima-u.ac.jp/VFlib/
 BuildRoot: %{_tmppath}/%{name}-%{version}-root
-BuildPreReq:   freetype-devel XFree86-devel
+BuildPreReq:   freetype-devel
+%if %{use_X}
+BuildPreReq: XFree86-devel
+%endif
 
 ## re-compressed bzip2 instead of gzip
 # Source: 
ftp://TypeHack.aial.hiroshima-u.ac.jp/pub/TypeHack/%{name}-%{version}.tar.gz
@@ -108,7 +118,11 @@
 autoconf
 
 %build
-OPTS="--with-x --with-freetype --enable-shared --enable-static"
+%if %{use_X}
+   OPTS="--with-x --with-freetype --enable-shared --enable-static"
+%else 
+   OPTS="--without-x --with-freetype --enable-shared --enable-static"
+%endif
 if [ -d %{_includedir}/freetype1 ]; then
 %configure ${OPTS}
--with-freetype-includedir=%{_includedir}/freetype1/freetype
 else
@@ -130,11 +144,13 @@
 (cd $RPM_BUILD_ROOT%{_sysconfdir} ; ln -fs
..%{_datadir}/VFlib/%{version}/vfontcap .)   
 (cd $RPM_BUILD_ROOT%{_sysconfdir} ; ln -fs
..%{_datadir}/VFlib/%{version}/vfontcap.ja .)
+%if %{use_X}
 install -c -m 0755 tools/.libs/disol  $RPM_BUILD_ROOT%{_bindir}
 install -c -m 0755 tools/.libs/fmtest $RPM_BUILD_ROOT%{_bindir}
 install -c -m 0755 tools/.libs/kban   $RPM_BUILD_ROOT%{_bindir}
 install -c -m 0755 tools/.libs/vfperf $RPM_BUILD_ROOT%{_bindir}
 install -c -m 0755 tools/.libs/vftest $RPM_BUILD_ROOT%{_bindir}
+%endif
 
 cp -ar jTeX $RPM_BUILD_ROOT%{_datadir}/VFlib/VFjfm
 cp -ar dynafont $RPM_BUILD_ROOT%{_datadir}/VFlib/VFjfm
@@ -168,12 +184,14 @@
 %{_bindir}/ttindex  
 %{_bindir}/bdfindex 
 %{_bindir}/fwindex  
+%if %{use_X}
 %{_bindir}/disol
 %{_bindir}/fmtest
 %{_bindir}/kban  
 %{_bindir}/ktest 
 %{_bindir}/vfperf
 %{_bindir}/vftest
+%endif
 %{_libdir}/lib*.so.*
 %{_datadir}/VFlib/%{version}/vfontcap
 %{_datadir}/VFlib/%{version}/vfontcap.bdf
Comment 1 Akira TAGOH 2005-02-17 04:13:15 EST
Well, what do you want to do? if you don't just want to install
xorg-x11 by VFlib2, I'd recommend to separate out the binaries which
depends on X to the sub package. does it make sense?
Comment 2 Philip Gwyn 2005-02-17 14:50:12 EST
Yes.  In fact, it's a better idea then having with-X and without-X
packages.  Is there any chance this would make it into the distro?
Comment 3 Akira TAGOH 2005-02-18 03:05:22 EST
Yes, will do soon.
Comment 4 Akira TAGOH 2005-02-23 01:57:22 EST
Fixed in 2.25.6-27 and VFlib2-xtools contains the utilities which depends on X

Note You need to log in before you can comment on or make changes to this bug.