Jump to content

Phil Edwards

Members
  • Posts

    40
  • Joined

  • Last visited

Profile Information

  • Gender
    Male

Phil Edwards's Achievements

New Here

New Here (1/7)

0

Reputation

  1. I can't see any obvious way to edit the title of this topic to add '[solved]'. Prior to the 'new look' on the board, you just had to edit your original post, but that doesn't give me an option to change the topic title any more...
  2. I've built several RPMs for previous versions of Mandriva up to and including 2008.1. I've recently upgraded to 2009.1 and I'm having a minor problem building an RPM which I can't seem to resolve. The package being built is a python-sybase module to allow access to Sybase and MS-SQL databases from a Python script. My spec file looks like this: %define name python-sybase %define version 0.39 %define release 1 %define pyver %(python -c "import sys; print '%s.%s' % sys.version_info[0:2]") Name: %{name} Summary: Python Sybase RDBMS access module Version: %{version} Release: %{release} Source0: http://downloads.sourceforge.net/python-sybase/python-sybase-%{version}.tar.bz2 Source1: http://python-sybase.sourceforge.net/download/python-sybase-docs-%{version}.tar.bz2 Patch1: python-sybase-%{version}.patch URL: http://python-sybase.sourceforge.net/ Group: Development/Python BuildRoot: %{_tmppath}/%{name}-buildroot License: BSD-Style license Requires: python >= %{pyver} BuildRequires: libfreetds-devel, libfreetds0, libltdl-devel, libunixODBC-devel, libpython%{pyver}-devel, python-setuptools, python-pkg-resources, latex2html %description Provides a Python interface to the Sybase relational database system. The Sybase package supports all of the Python Database API, version 2.0 with extensions. %prep [ "%{buildroot}" != "/" ] && rm -rf %{buildroot} %setup -n python-sybase-%{version} %setup -D -T -a 1 %patch1 -p1 %build python setup.py build_ext -D HAVE_FREETDS -U WANT_BULKCOPY #builddir is [/home/phile/rpm/BUILD] #buildroot is [/home/phile/rpm/BUILDROOT/python-sybase-0.39-1.i386] #_datadir is [/usr/share] #_defaultdocdir is [%_datadir/doc] %install python setup.py install --root=$RPM_BUILD_ROOT %clean [ "%{buildroot}" != "/" ] && rm -rf %{buildroot} %files %defattr(-,root,root,0755) %doc doc/sybase/* doc/sybase/icons/* ChangeLog LICENCE TODO /usr/lib/python%{pyver}/site-packages/* %changelog * Tue Sep 15 2009 Phil Edwards <phil@linux2000.com> 0.39-1pke - Initial RPM build for Mandriva 2009.1 I have the following entries in my ~/.rpmmacros file: %_topdir %(echo $HOME)/rpm %_tmppath %(echo $HOME)/rpm/tmp # If you want your packages to be GPG signed automatically, add these three lines # replacing 'Mandrivalinux' with your GPG name. You may also use rpm --resign # to sign the packages later. %_signature gpg %_gpg_name Phil Edwards %_gpg_path ~/.gnupg # Add your name and e-mail into the %packager field below. You may also want to # also replace vendor with yourself. %packager Phil Edwards <phil@linux2000.com> %distribution Mandriva Linux %vendor Mandriva # If you want your packages to have your own distsuffix instead of mdv, add it # here like this %distsuffix pke %debug_package %{nil} The package builds correctly with no errors. When the resulting RPM files get written, my distsuffix parameter is being ignored: [phile@mdv2009-1:/home/phile/rpm/RPMS/i586] $ ls -l total 216 -rw-r--r-- 1 phile phile 102711 2009-09-16 09:15 python-sybase-0.39-1.i586.rpm The name I am expecting to see for my package is python-sybase-0.39-1pke.i586.rpm - I can make this happen by changing the '%define release' line in the spec file, but I have always been able to set this in my .rpmmacros file in the past. Has something changed in the way rpmbuild works in 2009.1 or have I made some stupid mistake? :-)
  3. I knew it would be something simple. Thanks, Greg.
  4. I have a Mandriva 2008.1 server hosted with the ISP that I work for. I have taken the vanilla postfix source RPM, patched it to include support for sqlite3 lookup maps and built/installed the resulting custom package. This all works as expected. The problem that I now face is how to tell urpmi to ignore any further postfix updates that are released, since installing an updated Mandriva RPM would break the sqlite3 functionality that I have added. In RedHat Enterprise 5.x, which uses yum as its package manager, this is trivial to achieve - I would simply add 'exclude=postfix' to the config file for my updates repository. Is there a way to do the same with urpmi? I've looked through the man pages but not found an answer.
  5. Well, according to bugzilla, Frederic owned up to breaking it, Olivier has tested the fix, now we're just waiting for somebody to push the updated package out so the mirrors can pick it up. Guess I'll just have to sit and wait...
  6. For quite a while now, every time I fire up my MDV2008.1 machine, the update manager (i.e. /usr/bin/mdkapplet) tells me that there is a newer version of the Evolution mail client available, but it can't be installed due to a missing dependency. Running an update from the command line confirms this: [phile@localhost:/home/phile] $ sudo urpmi --auto --auto-select --update Some requested packages cannot be installed: evolution-2.22.3.1-1.1mdv2008.1.i586 (due to unsatisfied libgpilotdconduit.so.2) evolution-exchange-2.22.3-1.1mdv2008.1.i586 (due to unsatisfied libgpilotdconduit.so.2) [phile@localhost:/home/phile] $ rpm -q --whatprovides libgpilotdconduit no package provides libgpilotdconduit Based on past experience, this sort of error generally tends to be due to the repository mirror that I'm using being a bit out of date and it usually sorts itself out within a couple of days. I've been getting this message for the best part of 2 weeks and it shows no signs of going away. Other updates have been installed as normal during this period. Has anybody else come across this and figured out a fix for it?
  7. Yikes! Package manager is now furiously downloading and installing no less than 137 RPMs for me. Thank $DEITY for fast Internet connections.
  8. Wot he said - xfce4 is a lovely desktop environment and it's lean enough to work well on the most modest of hardware. In fact, I think I'll install it and use it for a while to see how I get on with it for everyday tasks. I've upgraded my laptop to 2009.0 and I'm happier with it now than I was to start with - just a case of getting used to the KDE4 way of doing things.
  9. Not if you're going to continue using the Orinoco card. :-( The orinoco_cs driver has no WPA/WPA2 support at all - it's quite an old card now (I have one at home that is effectively useless to me) and it's unlikely that anyone is going to want to rewrite the driver just for WPA. I'd suggest that your best option would be to get a newer card - a search on here should turn up some posts showing which cards people have had success with. I've got a Dell Latitude D830 laptop which came with a Broadcom internal wireless card with non-existent Linux support. I bought a pair of Intel 3945ABG cards from e-bay and fitted one of those instead. Job done.
  10. Barking slightly up the wrong tree, methinks... :D Instead of restricting access to the files using the mount command, you should look at setting the permissions on the files so that they match up with what you want, i.e. for all files to be read/write for root but read only for everyone else. Starting off with 'cd /path/to/the/files/in/question', you should then: find . -type f | xargs chown root:root find . -type f | xargs chmod 644 The first command finds all normal files, i.e. it ignores directory entries, symbolic links, etc and changes the file owner and group to root. The second command finds all normal files and makes them read/write for the owner (root) and read-only for everyone else.
  11. Some things that are worth pointing out: There is a user group called 'wheel' that will be present on every Mandriva install. There is also the 'sudo' utility which allows certain commands to be run as root by ordinary users. This is configured by running 'visudo' as root. One approach to your scripting problem would be: 1. Add all of the users that need to be able to use your script into the 'wheel' group 2. Use 'visudo' and uncomment the line which allows members of the 'wheel' group to run any command without having to enter the root password 3. At the start of your script have something like this: CHK=`id|grep wheel` if [ "$CHK" = "" ]; then echo -e "Insufficient privileges to run this script - contact your system administrator" exit 0 fi This allows you to restrict script execution to members of the wheel group. It's not best practice in terms of security to give a bunch of users free rein over your system, which is essentially what I'm suggesting here that you do! :unsure: A better solution would be to have a read through the man pages for the sudo and visudo commands and see if you can work out how to add a group of your own and have the members of that group restricted to running only a limited number of commands, i.e. only the commands that are executred inside your script.
  12. Thanks Lardy and sorry for the late reply. That didn't get rid of it unfortunately. Next time I log in to my machine, I'll take a look at what processes are running and see if that gives me a clue as to where it's coming from.
  13. I feel embarrassed at having to ask this, as it's something I should either know or at least be able to find out by myself... I installed 2008.1 on my new laptop about 6 weeks ago. Last week, I realized that I hadn't copied my GPG keys over from my previous install. I retrieved the keys (I have 1 for personal use, 1 for work use) etc from my pre-upgrade backup and checked to make sure I could sign and encrypt plain text files with the keys. Ever since then, whenever I log in to KDE, I get prompted for the passphrase for my personal GPG key. Where does this get launched from and how can I switch it off? I've trawled around in the startup scripts that I think are relevant, but I can't find anywhere that the prompt might be getting generated.
×
×
  • Create New...