-
-
Notifications
You must be signed in to change notification settings - Fork 3.5k
fix(main/nwipe): package belongs to root-repo #25269
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
Conversation
I'm not sure if I have an SD card to actually test the erasing functionality on at the moment, but I did notice this error and several other errors during startup on my rooted device:
Let's also try to prepend Here's a patch I made that fixes the above error, replacing it with this message: diff --git a/packages/nwipe/fix-hardcoded-paths.patch b/packages/nwipe/fix-hardcoded-paths.patch
index eff2184e95..2c6c9c056d 100644
--- a/packages/nwipe/fix-hardcoded-paths.patch
+++ b/packages/nwipe/fix-hardcoded-paths.patch
@@ -104,3 +104,22 @@
{
nwipe_log( NWIPE_LOG_WARNING, "modprobe command not found. Install kmod package (modprobe)) !" );
nwipe_log( NWIPE_LOG_WARNING, "Most temperature monitoring may be unavailable as module drivetemp" );
+--- a/src/conf.c
++++ b/src/conf.c
+@@ -38,11 +38,11 @@
+ config_t nwipe_cfg;
+ config_setting_t *nwipe_conf_setting, *group_organisation, *root, *group, *previous_group, *setting;
+ const char* nwipe_conf_str;
+-char nwipe_config_directory[] = "/etc/nwipe";
+-char nwipe_config_file[] = "/etc/nwipe/nwipe.conf";
+-char nwipe_customers_file[] = "/etc/nwipe/nwipe_customers.csv";
+-char nwipe_customers_file_backup[] = "/etc/nwipe/nwipe_customers.csv.backup";
+-char nwipe_customers_file_backup_tmp[] = "/etc/nwipe/nwipe_customers.csv.backup.tmp";
++char nwipe_config_directory[] = "@TERMUX_PREFIX@/etc/nwipe";
++char nwipe_config_file[] = "@TERMUX_PREFIX@/etc/nwipe/nwipe.conf";
++char nwipe_customers_file[] = "@TERMUX_PREFIX@/etc/nwipe/nwipe_customers.csv";
++char nwipe_customers_file_backup[] = "@TERMUX_PREFIX@/etc/nwipe/nwipe_customers.csv.backup";
++char nwipe_customers_file_backup_tmp[] = "@TERMUX_PREFIX@/etc/nwipe/nwipe_customers.csv.backup.tmp";
+
+ /*
+ * Checks for the existence of nwipe.conf and nwipe_customers.csv
If you would like you can put this in this PR, or if you prefer this to be in a different PR, I could open a separate one after this one is completed. |
98d34e1
to
dcce296
Compare
Fix added, thanks. Although this package is kind of useless and I think no one actually used it.
I think it should be moved rather to disabled packages now. |
If you believe it should be disabled, probably that's ok and you're likely correct that not many people need to secure erase a drive using rooted Android and don't have a different device to do the erasing, so I don't think anyone would mind this, but I don't agree exactly with all the same reasons as you, because it should be noted that wget https://downloads.sourceforge.net/sourceforge/hdparm/hdparm-9.65.tar.gz
tar xvf hdparm-9.65.tar.gz
cd hdparm-9.65/
make
sudo ./hdparm -I /dev/block/sda and git clone https://github.com/smartmontools/smartmontools.git
cd smartmontools
./autogen.sh
./configure --prefix="$PREFIX" \
--sbindir="$PREFIX/bin" \
--with-scriptpath="$PREFIX/bin"
make LDFLAGS="-landroid-glob"
src/smartctl -h however, |
Actually, I realized that there are open requests for AUR's package has |
Yes, let's add these packages. |
The packages are now available, after installing them and also installing the artifact from here, It did show this in the log:
however I believe it can be assumed that if someone has an SD card and tries to erase it, this will work now. so it seems like, now you could just add the package |
This package refuses to run without root permissions and should be placed to the root-repo. Additionally add more fixes for hardcoded paths to prevent errors related to configuration files.
This package refuses to run without root permissions and should be placed to the root-repo.