Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update the build and packaging script for Fedora 37. #109

Merged
merged 7 commits into from
Dec 7, 2022
Merged

Conversation

jewelpit
Copy link
Member

@jewelpit jewelpit commented Dec 7, 2022

Since Ubuntu dropped support for building RPMs in 20.04, but we need to build against a version of GNOME that didn't ship until Ubuntu 22.10, we have to split the build into a .deb half and a .rpm half. The .deb half must be run under Debian or Ubuntu, while the .rpm half must be run on a Fedora or RHEL machine. This allows us to release coreyberla's fix, resolving #108 and #101.

New package metadata (package name and signature match):

[jpitts@fedora nautilus-dropbox]$ rpm -qip /tmp/dbx_build/result/fedora/37/x86_64/nautilus-dropbox-2022.12.05-1.fedora.x86_64.rpm 
Name        : nautilus-dropbox
Version     : 2022.12.05
Release     : 1.fc37
Architecture: x86_64
Install Date: (not installed)
Group       : User Interface/Desktops
Size        : 205877
License     : GPLv3
Signature   : RSA/SHA256, Wed 07 Dec 2022 11:17:11 AM PST, Key ID fc918b335044912e
Source RPM  : nautilus-dropbox-2022.12.05-1.fc37.src.rpm
Build Date  : Wed 07 Dec 2022 11:16:46 AM PST
Build Host  : fedora.local
URL         : https://www.dropbox.com/
Summary     : Dropbox integration for Nautilus
Description :
Nautilus Dropbox is an extension that integrates
the Dropbox web service with your GNOME Desktop.

Check us out at https://www.dropbox.com/

Old package metadata:

[jpitts@fedora nautilus-dropbox]$ rpm -qip 35/x86_64/nautilus-dropbox-2020.03.04-1.fedora.x86_64.rpm 
Name        : nautilus-dropbox
Version     : 2020.03.04
Release     : 1.fc21
Architecture: x86_64
Install Date: (not installed)
Group       : User Interface/Desktops
Size        : 198248
License     : GPLv3
Signature   : RSA/SHA1, Wed 04 Mar 2020 03:33:07 PM PST, Key ID fc918b335044912e
Source RPM  : nautilus-dropbox-2020.03.04-1.fc21.src.rpm
Build Date  : Wed 04 Mar 2020 03:33:05 PM PST
Build Host  : vagrant.vm
URL         : https://www.dropbox.com/
Summary     : Dropbox integration for Nautilus
Description :
Nautilus Dropbox is an extension that integrates
the Dropbox web service with your GNOME Desktop.

Check us out at https://www.dropbox.com/

@jewelpit jewelpit requested a review from goffrie December 7, 2022 00:29
jewelpit and others added 2 commits December 7, 2022 11:25
* Add scheduled canary build.

This feels like a necessary thing to have, especially in light of the GNOME 43 upgrade.

* Move to correct folder.

* Update installed packages.

* add libgtk-4-dev for ubuntu

Co-authored-by: Geoffry Song <goffrie@dropbox.com>
@jewelpit jewelpit changed the title [WIP] Update the build and packaging script for Fedora 37. Update the build and packaging script for Fedora 37. Dec 7, 2022
@jewelpit
Copy link
Member Author

jewelpit commented Dec 7, 2022

This is now out of WIP and ready for review :) Scratch that it looks like it picked up a merge conflict, lemme resolve and resend.

@jewelpit
Copy link
Member Author

jewelpit commented Dec 7, 2022

Okay now it's ready.

Copy link
Contributor

@goffrie goffrie left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If it works it works, I admit that I don't really know how rpm works.

Incidentally we should probably also get rid of the sketchy code included in the RPM that traverses /home/*/.dropbox-dist and deletes old Dropbox versions (see generate-rpm.sh)

HOWTO_PACKAGE.md Outdated
Probably you have to run `build_packages.py` command with `sudo` permission which
means you should add your root account to the mock group. Otherwise, you will see
`The password you typed is invalid.` error.
4. On a Fedora machine:
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this numbering seems wrong ;)

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Step three knows what it did >:(

@@ -29,7 +29,7 @@ cat <<EOF > $HOME/.rpmmacros
%_tmppath $(pwd)/rpmbuild
%_smp_mflags -j3
%_signature gpg
%_gpg_name 3565780E
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

i was curious and it turns out this was rian hunter's key 😆

generate-rpm.sh Outdated
Comment on lines 221 to 228
# Old versions of the rpm delete these files in postun. Fortunately we have saved a backup.
if [ ! -e %{_libdir}/nautilus/extensions-4/libnautilus-dropbox.so ]; then
if [ -e %{_libdir}/nautilus/extensions-4/libnautilus-dropbox.so.bak ]; then
mv -f %{_libdir}/nautilus/extensions-4/libnautilus-dropbox.so{.bak,}
fi
fi

rm -f %{_libdir}/nautilus/extensions-3.0/libnautilus-dropbox.so.bak
rm -f %{_libdir}/nautilus/extensions-2.0/libnautilus-dropbox.so.bak
rm -f %{_libdir}/nautilus/extensions-4/libnautilus-dropbox.so.bak
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm guessing this is not necessary any more

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oh, right. Old versions wouldn't be touching this path anyway.

generate-rpm.sh Outdated
Comment on lines 121 to 124
if [ \$1 -gt 1 ] ; then
# Old versions of the rpm delete the files in postun. So just in case let's make a backup copy. The backup copy will be restored in posttrans.
ln -f %{_libdir}/nautilus/extensions-3.0/libnautilus-dropbox.so{,.bak}
ln -f %{_libdir}/nautilus/extensions-2.0/libnautilus-dropbox.so{,.bak}
ln -f %{_libdir}/nautilus/extensions-4/libnautilus-dropbox.so{,.bak}
fi
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

and this

@jewelpit jewelpit merged commit 8cc1635 into master Dec 7, 2022
@jewelpit jewelpit deleted the fedora37 branch December 7, 2022 21:23
@stevo-knievo
Copy link

I just upgraded to F37. But still can't find the package.

dnf search nautilus-dropbox

sorry if I missed something.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants